2 * Copyright 2008 Extreme Engineering Solutions, Inc.
4 * SPDX-License-Identifier: GPL-2.0+
13 * Determine if a board's flashes are write protected
15 int board_flash_wp_on(void)
17 if (pca953x_get_val(CONFIG_SYS_I2C_PCA953X_ADDR0) &
18 CONFIG_SYS_PCA953X_NVM_WP)
26 * Return a board's derivative model number. For example:
27 * return 2 for the XPedite5372 and return 1 for the XPedite5201.
29 uint get_board_derivative(void)
31 #if defined(CONFIG_MPC85xx)
32 volatile ccsr_gur_t *gur = (void *)CONFIG_SYS_MPC85xx_GUTS_ADDR;
33 #elif defined(CONFIG_MPC86xx)
34 volatile immap_t *immap = (immap_t *)CONFIG_SYS_CCSRBAR;
35 volatile ccsr_gur_t *gur = &immap->im_gur;
39 * The top 4 lines of the local bus address are pulled low/high and
40 * can be read to determine the least significant digit of a board's
43 return gur->gpporcr >> 28;