-+ __copy_to_user((BOARD_IOCTL_PARMS*)arg, &ctrlParms, sizeof(BOARD_IOCTL_PARMS));
-+ ret = 0;
-+ }
-+ }
-+ else {
-+ ret = -EFAULT;
-+ }
-+ break;
-+
-+ case BOARD_IOCTL_GET_ENET_CFG:
-+ if (copy_from_user((void*)&ctrlParms, (void*)arg, sizeof(ctrlParms)) == 0) {
-+ ETHERNET_MAC_INFO EnetInfos[BP_MAX_ENET_MACS];
-+ if (BpGetEthernetMacInfo(EnetInfos, BP_MAX_ENET_MACS) == BP_SUCCESS) {
-+ if (ctrlParms.strLen == sizeof(EnetInfos)) {
-+ __copy_to_user(ctrlParms.string, EnetInfos, sizeof(EnetInfos));
-+ ctrlParms.result = 0;
-+ __copy_to_user((BOARD_IOCTL_PARMS*)arg, &ctrlParms, sizeof(BOARD_IOCTL_PARMS));
-+ ret = 0;
-+ } else
-+ ret = -EFAULT;
-+ }
-+ else {
-+ ret = -EFAULT;
-+ }
-+ break;
-+ }
-+ else {
-+ ret = -EFAULT;
-+ }
-+ break;
-+//<<JUNHON, 2004/09/15, get reset button status , tim hou , 05/04/12
-+ case BOARD_IOCTL_GET_RESETHOLD:
-+ ctrlParms.result = kerSysGetResetHold();
-+ __copy_to_user((BOARD_IOCTL_PARMS*)arg, &ctrlParms, sizeof(BOARD_IOCTL_PARMS));
-+ ret = 0;
-+ break;
-+//>>JUNHON, 2004/09/15
-+
-+
-+#if defined (WIRELESS)
-+ case BOARD_IOCTL_GET_WLAN_ANT_INUSE:
-+ if (copy_from_user((void*)&ctrlParms, (void*)arg, sizeof(ctrlParms)) == 0) {
-+ unsigned short antInUse = 0;
-+ if (BpGetWirelessAntInUse(&antInUse) == BP_SUCCESS) {
-+ if (ctrlParms.strLen == sizeof(antInUse)) {
-+ __copy_to_user(ctrlParms.string, &antInUse, sizeof(antInUse));
-+ ctrlParms.result = 0;
-+ __copy_to_user((BOARD_IOCTL_PARMS*)arg, &ctrlParms, sizeof(BOARD_IOCTL_PARMS));
-+ ret = 0;
-+ } else
-+ ret = -EFAULT;
-+ }
-+ else {
-+ ret = -EFAULT;
-+ }
-+ break;
-+ }
-+ else {
-+ ret = -EFAULT;
-+ }
-+ break;
-+#endif
-+ case BOARD_IOCTL_SET_TRIGGER_EVENT:
-+ if (copy_from_user((void*)&ctrlParms, (void*)arg, sizeof(ctrlParms)) == 0) {
-+ BOARD_IOC *board_ioc = (BOARD_IOC *)flip->private_data;
-+ ctrlParms.result = -EFAULT;
-+ ret = -EFAULT;
-+ if (ctrlParms.strLen == sizeof(unsigned long)) {
-+ board_ioc->eventmask |= *((int*)ctrlParms.string);
-+#if defined (WIRELESS)
-+ if((board_ioc->eventmask & SES_EVENTS)) {
-+ if(sesBtn_irq != BP_NOT_DEFINED) {
-+ BcmHalInterruptEnable(sesBtn_irq);
-+ ctrlParms.result = 0;
-+ ret = 0;
-+ }
-+ }
-+#endif
-+ __copy_to_user((BOARD_IOCTL_PARMS*)arg, &ctrlParms, sizeof(BOARD_IOCTL_PARMS));
-+ }
-+ break;
-+ }
-+ else {
-+ ret = -EFAULT;
-+ }
-+ break;
-+
-+ case BOARD_IOCTL_GET_TRIGGER_EVENT:
-+ if (copy_from_user((void*)&ctrlParms, (void*)arg, sizeof(ctrlParms)) == 0) {
-+ BOARD_IOC *board_ioc = (BOARD_IOC *)flip->private_data;
-+ if (ctrlParms.strLen == sizeof(unsigned long)) {
-+ __copy_to_user(ctrlParms.string, &board_ioc->eventmask, sizeof(unsigned long));
-+ ctrlParms.result = 0;
-+ __copy_to_user((BOARD_IOCTL_PARMS*)arg, &ctrlParms, sizeof(BOARD_IOCTL_PARMS));
-+ ret = 0;
-+ } else
-+ ret = -EFAULT;
-+
-+ break;
-+ }
-+ else {
-+ ret = -EFAULT;
-+ }
-+ break;
-+
-+ case BOARD_IOCTL_UNSET_TRIGGER_EVENT:
-+ if (copy_from_user((void*)&ctrlParms, (void*)arg, sizeof(ctrlParms)) == 0) {
-+ if (ctrlParms.strLen == sizeof(unsigned long)) {
-+ BOARD_IOC *board_ioc = (BOARD_IOC *)flip->private_data;
-+ board_ioc->eventmask &= (~(*((int*)ctrlParms.string)));
-+ ctrlParms.result = 0;
-+ __copy_to_user((BOARD_IOCTL_PARMS*)arg, &ctrlParms, sizeof(BOARD_IOCTL_PARMS));
-+ ret = 0;
-+ } else
-+ ret = -EFAULT;
-+
-+ break;
-+ }
-+ else {
-+ ret = -EFAULT;
-+ }
-+ break;
-+#if defined (WIRELESS)
-+ case BOARD_IOCTL_SET_SES_LED:
-+ if (copy_from_user((void*)&ctrlParms, (void*)arg, sizeof(ctrlParms)) == 0) {
-+ if (ctrlParms.strLen == sizeof(int)) {
-+ sesLed_ctrl(*(int*)ctrlParms.string);
-+ ctrlParms.result = 0;
-+ __copy_to_user((BOARD_IOCTL_PARMS*)arg, &ctrlParms, sizeof(BOARD_IOCTL_PARMS));
-+ ret = 0;
-+ } else
-+ ret = -EFAULT;
-+
-+ break;
-+ }
-+ else {
-+ ret = -EFAULT;
-+ }
-+ break;
-+#endif
-+
-+ case BOARD_IOCTL_SET_MONITOR_FD:
-+ if (copy_from_user((void*)&ctrlParms, (void*)arg, sizeof(ctrlParms)) == 0) {
-+ int fput_needed = 0;
-+
-+ g_monitor_file = fget_light( ctrlParms.offset, &fput_needed );
-+ if( g_monitor_file ) {
-+ /* Hook this file descriptor's poll function in order to set
-+ * the exception descriptor when there is a change in link
-+ * state.
-+ */
-+ g_monitor_task = current;
-+ g_orig_fop_poll = kerSysMonitorPollHook;
-+ /*g_orig_fop_poll = g_monitor_file->f_op->poll;
-+ g_monitor_file->f_op->poll = kerSysMonitorPollHook;*/
-+ }
-+ }
-+ break;
-+
-+ case BOARD_IOCTL_WAKEUP_MONITOR_TASK:
-+ kerSysWakeupMonitorTask();
-+ break;
-+
-+ default:
-+ ret = -EINVAL;
-+ ctrlParms.result = 0;
-+ printk("board_ioctl: invalid command %x, cmd %d .\n",command,_IOC_NR(command));
-+ break;
-+
-+ } /* switch */
-+
-+ return (ret);
-+
-+} /* board_ioctl */
-+
-+/***************************************************************************
-+ * SES Button ISR/GPIO/LED functions.
-+ ***************************************************************************/
-+#if defined (WIRELESS)
-+static irqreturn_t sesBtn_isr(int irq, void *dev_id, struct pt_regs *ptregs)
-+{
-+#if defined(_BCM96338_) || defined(CONFIG_BCM96338)
-+ unsigned long gpio_mask = GPIO_NUM_TO_MASK(sesBtn_gpio);
-+ volatile unsigned long *gpio_reg = &GPIO->GPIOio;
-+#endif
-+#if defined(_BCM96345_) || defined(CONFIG_BCM96345)
-+ unsigned short gpio_mask = GPIO_NUM_TO_MASK(sesBtn_gpio);
-+ volatile unsigned short *gpio_reg = &GPIO->GPIOio;
-+#endif
-+#if defined(_BCM96348_) || defined (CONFIG_BCM96348)
-+ unsigned long gpio_mask = GPIO_NUM_TO_MASK(sesBtn_gpio);
-+ volatile unsigned long *gpio_reg = &GPIO->GPIOio;
-+
-+ if( (sesBtn_gpio & ~BP_ACTIVE_MASK) >= 32 )
-+ {
-+ gpio_mask = GPIO_NUM_TO_MASK_HIGH(sesBtn_gpio);
-+ gpio_reg = &GPIO->GPIOio_high;
-+ }
-+#endif
-+
-+ if (!(*gpio_reg & gpio_mask)){
-+ wake_up_interruptible(&g_board_wait_queue);
-+ return IRQ_RETVAL(1);
-+ } else {
-+ return IRQ_RETVAL(0);
-+ }
-+}
-+
-+static void __init sesBtn_mapGpio()
-+{
-+ if( BpGetWirelessSesBtnGpio(&sesBtn_gpio) == BP_SUCCESS )
-+ {
-+ printk("SES: Button GPIO 0x%x is enabled\n", sesBtn_gpio);
-+ }
-+}
-+
-+static void __init sesBtn_mapIntr(int context)
-+{
-+ if( BpGetWirelessSesExtIntr(&sesBtn_irq) == BP_SUCCESS )
-+ {
-+ printk("SES: Button Interrupt 0x%x is enabled\n", sesBtn_irq);
-+ }
-+ else
-+ return;
-+
-+ sesBtn_irq += INTERRUPT_ID_EXTERNAL_0;
-+
-+ if (BcmHalMapInterrupt((FN_HANDLER)sesBtn_isr, context, sesBtn_irq)) {
-+ printk("SES: Interrupt mapping failed\n");
-+ }
-+ BcmHalInterruptEnable(sesBtn_irq);
-+}
-+
-+
-+static unsigned int sesBtn_poll(struct file *file, struct poll_table_struct *wait)
-+{
-+#if defined(_BCM96338_) || defined(CONFIG_BCM96338)
-+ unsigned long gpio_mask = GPIO_NUM_TO_MASK(sesBtn_gpio);
-+ volatile unsigned long *gpio_reg = &GPIO->GPIOio;
-+#endif
-+#if defined(_BCM96345_) || defined(CONFIG_BCM96345)
-+ unsigned short gpio_mask = GPIO_NUM_TO_MASK(sesBtn_gpio);
-+ volatile unsigned short *gpio_reg = &GPIO->GPIOio;
-+#endif
-+#if defined(_BCM96348_) || defined (CONFIG_BCM96348)
-+ unsigned long gpio_mask = GPIO_NUM_TO_MASK(sesBtn_gpio);
-+ volatile unsigned long *gpio_reg = &GPIO->GPIOio;
-+
-+ if( (sesBtn_gpio & ~BP_ACTIVE_MASK) >= 32 )
-+ {
-+ gpio_mask = GPIO_NUM_TO_MASK_HIGH(sesBtn_gpio);
-+ gpio_reg = &GPIO->GPIOio_high;
-+ }
-+#endif
-+
-+ if (!(*gpio_reg & gpio_mask)){
-+ return POLLIN;
-+ }
-+ return 0;
-+}
-+
-+static ssize_t sesBtn_read(struct file *file, char __user *buffer, size_t count, loff_t *ppos)
-+{
-+ volatile unsigned int event=0;
-+ ssize_t ret=0;
-+
-+#if defined(_BCM96338_) || defined (CONFIG_BCM96338)
-+ unsigned long gpio_mask = GPIO_NUM_TO_MASK(sesBtn_gpio);
-+ volatile unsigned long *gpio_reg = &GPIO->GPIOio;
-+#endif
-+#if defined(_BCM96345_) || defined (CONFIG_BCM96345)
-+ unsigned short gpio_mask = GPIO_NUM_TO_MASK(sesBtn_gpio);
-+ volatile unsigned short *gpio_reg = &GPIO->GPIOio;
-+#endif
-+#if defined(_BCM96348_) || defined (CONFIG_BCM96348)
-+ unsigned long gpio_mask = GPIO_NUM_TO_MASK(sesBtn_gpio);
-+ volatile unsigned long *gpio_reg = &GPIO->GPIOio;
-+
-+ if( (sesBtn_gpio & ~BP_ACTIVE_MASK) >= 32 )
-+ {
-+ gpio_mask = GPIO_NUM_TO_MASK_HIGH(sesBtn_gpio);
-+ gpio_reg = &GPIO->GPIOio_high;
-+ }
-+#endif
-+
-+ if(*gpio_reg & gpio_mask){
-+ BcmHalInterruptEnable(sesBtn_irq);
-+ return ret;
-+ }
-+ event = SES_EVENTS;
-+ __copy_to_user((char*)buffer, (char*)&event, sizeof(event));
-+ BcmHalInterruptEnable(sesBtn_irq);
-+ count -= sizeof(event);
-+ buffer += sizeof(event);
-+ ret += sizeof(event);
-+ return ret;
-+}
-+
-+static void __init sesLed_mapGpio()
-+{
-+ if( BpGetWirelessSesBtnGpio(&sesLed_gpio) == BP_SUCCESS )
-+ {
-+ printk("SES: LED GPIO 0x%x is enabled\n", sesBtn_gpio);
-+ }
-+}
-+
-+static void sesLed_ctrl(int action)
-+{
-+
-+ //char status = ((action >> 8) & 0xff); /* extract status */
-+ //char event = ((action >> 16) & 0xff); /* extract event */
-+ //char blinktype = ((action >> 24) & 0xff); /* extract blink type for SES_LED_BLINK */
-+
-+ BOARD_LED_STATE led;
-+
-+ if(sesLed_gpio == BP_NOT_DEFINED)
-+ return;
-+
-+ action &= 0xff; /* extract led */
-+
-+ //printk("blinktype=%d, event=%d, status=%d\n",(int)blinktype, (int)event, (int)status);
-+
-+ switch (action)
-+ {
-+ case SES_LED_ON:
-+ //printk("SES: led on\n");
-+ led = kLedStateOn;
-+ break;
-+ case SES_LED_BLINK:
-+ //printk("SES: led blink\n");
-+ led = kLedStateSlowBlinkContinues;
-+ break;
-+ case SES_LED_OFF:
-+ default:
-+ //printk("SES: led off\n");
-+ led = kLedStateOff;
-+ }
-+
-+ kerSysLedCtrl(kLedSes, led);
-+}
-+
-+static void __init ses_board_init()
-+{
-+ sesBtn_mapGpio();
-+ sesBtn_mapIntr(0);
-+ sesLed_mapGpio();
-+}
-+static void __exit ses_board_deinit()
-+{
-+ if(sesBtn_irq)
-+ BcmHalInterruptDisable(sesBtn_irq);
-+}
-+#endif
-+
-+/***************************************************************************
-+ * Dying gasp ISR and functions.
-+ ***************************************************************************/
-+#define KERSYS_DBG printk
-+
-+#if defined(CONFIG_BCM96345)
-+#define CYCLE_PER_US 70
-+#elif defined(CONFIG_BCM96348) || defined(CONFIG_BCM96338)
-+/* The BCM6348 cycles per microsecond is really variable since the BCM6348
-+ * MIPS speed can vary depending on the PLL settings. However, an appoximate
-+ * value of 120 will still work OK for the test being done.
-+ */
-+#define CYCLE_PER_US 120
-+#endif
-+#define DG_GLITCH_TO (100*CYCLE_PER_US)
-+
-+static void __init kerSysDyingGaspMapIntr()
-+{
-+ unsigned long ulIntr;
-+
-+#if defined(CONFIG_BCM96348) || defined(_BCM96348_) || defined(CONFIG_BCM96338) || defined(_BCM96338_)
-+ if( BpGetAdslDyingGaspExtIntr( &ulIntr ) == BP_SUCCESS ) {
-+ BcmHalMapInterrupt((FN_HANDLER)kerSysDyingGaspIsr, 0, INTERRUPT_ID_DG);
-+ BcmHalInterruptEnable( INTERRUPT_ID_DG );
-+ }
-+#elif defined(CONFIG_BCM96345) || defined(_BCM96345_)
-+ if( BpGetAdslDyingGaspExtIntr( &ulIntr ) == BP_SUCCESS ) {
-+ ulIntr += INTERRUPT_ID_EXTERNAL_0;
-+ BcmHalMapInterrupt((FN_HANDLER)kerSysDyingGaspIsr, 0, ulIntr);
-+ BcmHalInterruptEnable( ulIntr );
-+ }
-+#endif
-+
-+}
-+
-+void kerSysSetWdTimer(ulong timeUs)
-+{
-+ TIMER->WatchDogDefCount = timeUs * (FPERIPH/1000000);
-+ TIMER->WatchDogCtl = 0xFF00;
-+ TIMER->WatchDogCtl = 0x00FF;
-+}
-+
-+ulong kerSysGetCycleCount(void)
-+{
-+ ulong cnt;
-+#ifdef _WIN32_WCE
-+ cnt = 0;
-+#else
-+ __asm volatile("mfc0 %0, $9":"=d"(cnt));
-+#endif
-+ return(cnt);
-+}
-+
-+static Bool kerSysDyingGaspCheckPowerLoss(void)
-+{
-+ ulong clk0;
-+ ulong ulIntr;
-+
-+ ulIntr = 0;
-+ clk0 = kerSysGetCycleCount();
-+
-+ UART->Data = 'D';
-+ UART->Data = '%';
-+ UART->Data = 'G';
-+
-+#if defined(CONFIG_BCM96345)
-+ BpGetAdslDyingGaspExtIntr( &ulIntr );
-+
-+ do {
-+ ulong clk1;
-+
-+ clk1 = kerSysGetCycleCount(); /* time cleared */
-+ /* wait a little to get new reading */
-+ while ((kerSysGetCycleCount()-clk1) < CYCLE_PER_US*2)
-+ ;
-+ } while ((0 == (PERF->ExtIrqCfg & (1 << (ulIntr + EI_STATUS_SHFT)))) && ((kerSysGetCycleCount() - clk0) < DG_GLITCH_TO));
-+
-+ if (PERF->ExtIrqCfg & (1 << (ulIntr + EI_STATUS_SHFT))) { /* power glitch */
-+ BcmHalInterruptEnable( ulIntr + INTERRUPT_ID_EXTERNAL_0);
-+ KERSYS_DBG(" - Power glitch detected. Duration: %ld us\n", (kerSysGetCycleCount() - clk0)/CYCLE_PER_US);
-+ return 0;
-+ }
-+#elif (defined(CONFIG_BCM96348) || defined(CONFIG_BCM96338)) && !defined(VXWORKS)
-+ do {
-+ ulong clk1;
-+
-+ clk1 = kerSysGetCycleCount(); /* time cleared */
-+ /* wait a little to get new reading */
-+ while ((kerSysGetCycleCount()-clk1) < CYCLE_PER_US*2)
-+ ;
-+ } while ((PERF->IrqStatus & (1 << (INTERRUPT_ID_DG - INTERNAL_ISR_TABLE_OFFSET))) && ((kerSysGetCycleCount() - clk0) < DG_GLITCH_TO));
-+
-+ if (!(PERF->IrqStatus & (1 << (INTERRUPT_ID_DG - INTERNAL_ISR_TABLE_OFFSET)))) {
-+ BcmHalInterruptEnable( INTERRUPT_ID_DG );
-+ KERSYS_DBG(" - Power glitch detected. Duration: %ld us\n", (kerSysGetCycleCount() - clk0)/CYCLE_PER_US);
-+ return 0;
-+ }
-+#endif
-+ return 1;
-+}
-+
-+static void kerSysDyingGaspShutdown( void )
-+{
-+ kerSysSetWdTimer(1000000);
-+#if defined(CONFIG_BCM96345)
-+ PERF->blkEnables &= ~(EMAC_CLK_EN | USB_CLK_EN | CPU_CLK_EN);
-+#elif defined(CONFIG_BCM96348)
-+ PERF->blkEnables &= ~(EMAC_CLK_EN | USBS_CLK_EN | USBH_CLK_EN | SAR_CLK_EN);
-+#endif
-+}
-+
-+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,0))
-+static irqreturn_t kerSysDyingGaspIsr(int irq, void * dev_id, struct pt_regs * regs)
-+#else
-+static unsigned int kerSysDyingGaspIsr(void)
-+#endif
-+{
-+ struct list_head *pos;
-+ CB_DGASP_LIST *tmp, *dsl = NULL;
-+
-+ if (kerSysDyingGaspCheckPowerLoss()) {
-+
-+ /* first to turn off everything other than dsl */
-+ list_for_each(pos, &g_cb_dgasp_list_head->list) {
-+ tmp = list_entry(pos, CB_DGASP_LIST, list);
-+ if(strncmp(tmp->name, "dsl", 3)) {
-+ (tmp->cb_dgasp_fn)(tmp->context);
-+ }else {
-+ dsl = tmp;
-+ }
-+ }
-+
-+ /* now send dgasp */
-+ if(dsl)
-+ (dsl->cb_dgasp_fn)(dsl->context);
-+
-+ /* reset and shutdown system */
-+ kerSysDyingGaspShutdown();
-+ }
-+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,0))
-+return( IRQ_HANDLED );
-+#else
-+ return( 1 );
-+#endif
-+}
-+
-+static void __init kerSysInitDyingGaspHandler( void )
-+{
-+ CB_DGASP_LIST *new_node;
-+
-+ if( g_cb_dgasp_list_head != NULL) {
-+ printk("Error: kerSysInitDyingGaspHandler: list head is not null\n");
-+ return;
-+ }
-+ new_node= (CB_DGASP_LIST *)kmalloc(sizeof(CB_DGASP_LIST), GFP_KERNEL);
-+ memset(new_node, 0x00, sizeof(CB_DGASP_LIST));
-+ INIT_LIST_HEAD(&new_node->list);
-+ g_cb_dgasp_list_head = new_node;
-+
-+} /* kerSysInitDyingGaspHandler */
-+
-+static void __exit kerSysDeinitDyingGaspHandler( void )
-+{
-+ struct list_head *pos;
-+ CB_DGASP_LIST *tmp;
-+
-+ if(g_cb_dgasp_list_head == NULL)
-+ return;
-+
-+ list_for_each(pos, &g_cb_dgasp_list_head->list) {
-+ tmp = list_entry(pos, CB_DGASP_LIST, list);
-+ list_del(pos);
-+ kfree(tmp);
-+ }
-+
-+ kfree(g_cb_dgasp_list_head);
-+ g_cb_dgasp_list_head = NULL;
-+
-+} /* kerSysDeinitDyingGaspHandler */
-+
-+void kerSysRegisterDyingGaspHandler(char *devname, void *cbfn, void *context)
-+{
-+ CB_DGASP_LIST *new_node;
-+
-+ if( g_cb_dgasp_list_head == NULL) {
-+ printk("Error: kerSysRegisterDyingGaspHandler: list head is null\n");
-+ return;
-+ }
-+
-+ if( devname == NULL || cbfn == NULL ) {
-+ printk("Error: kerSysRegisterDyingGaspHandler: register info not enough (%s,%x,%x)\n", devname, (unsigned int)cbfn, (unsigned int)context);
-+ return;
-+ }
-+
-+ new_node= (CB_DGASP_LIST *)kmalloc(sizeof(CB_DGASP_LIST), GFP_KERNEL);
-+ memset(new_node, 0x00, sizeof(CB_DGASP_LIST));
-+ INIT_LIST_HEAD(&new_node->list);
-+ strncpy(new_node->name, devname, IFNAMSIZ);
-+ new_node->cb_dgasp_fn = (cb_dgasp_t)cbfn;
-+ new_node->context = context;
-+ list_add(&new_node->list, &g_cb_dgasp_list_head->list);
-+
-+ printk("dgasp: kerSysRegisterDyingGaspHandler: %s registered \n", devname);
-+
-+} /* kerSysRegisterDyingGaspHandler */
-+
-+void kerSysDeregisterDyingGaspHandler(char *devname)
-+{
-+ struct list_head *pos;
-+ CB_DGASP_LIST *tmp;
-+
-+ if(g_cb_dgasp_list_head == NULL) {
-+ printk("Error: kerSysDeregisterDyingGaspHandler: list head is null\n");
-+ return;
-+ }
-+
-+ if(devname == NULL) {
-+ printk("Error: kerSysDeregisterDyingGaspHandler: devname is null\n");
-+ return;
-+ }
-+
-+ printk("kerSysDeregisterDyingGaspHandler: %s is deregistering\n", devname);
-+
-+ list_for_each(pos, &g_cb_dgasp_list_head->list) {
-+ tmp = list_entry(pos, CB_DGASP_LIST, list);
-+ if(!strcmp(tmp->name, devname)) {
-+ list_del(pos);
-+ kfree(tmp);
-+ printk("kerSysDeregisterDyingGaspHandler: %s is deregistered\n", devname);
-+ return;
-+ }
-+ }
-+ printk("kerSysDeregisterDyingGaspHandler: %s not (de)registered\n", devname);
-+
-+} /* kerSysDeregisterDyingGaspHandler */
-+
-+/***************************************************************************
-+ * MACRO to call driver initialization and cleanup functions.
-+ ***************************************************************************/
-+module_init( brcm_board_init );
-+module_exit( brcm_board_cleanup );
-+
-+EXPORT_SYMBOL(kerSysNvRamGet);
-+EXPORT_SYMBOL(dumpaddr);
-+EXPORT_SYMBOL(kerSysGetMacAddress);
-+EXPORT_SYMBOL(kerSysReleaseMacAddress);
-+EXPORT_SYMBOL(kerSysGetSdramSize);
-+EXPORT_SYMBOL(kerSysLedCtrl);
-+//<<JUNHON, 2004/09/15, get reset button status , tim hou , 05/04/12
-+EXPORT_SYMBOL(kerSysGetResetHold);
-+//>>JUNHON, 2004/09/15
-+EXPORT_SYMBOL(kerSysLedRegisterHwHandler);
-+EXPORT_SYMBOL(BpGetBoardIds);
-+EXPORT_SYMBOL(BpGetSdramSize);
-+EXPORT_SYMBOL(BpGetPsiSize);
-+EXPORT_SYMBOL(BpGetEthernetMacInfo);
-+EXPORT_SYMBOL(BpGetRj11InnerOuterPairGpios);
-+EXPORT_SYMBOL(BpGetPressAndHoldResetGpio);
-+EXPORT_SYMBOL(BpGetVoipResetGpio);
-+EXPORT_SYMBOL(BpGetVoipIntrGpio);
-+EXPORT_SYMBOL(BpGetPcmciaResetGpio);
-+EXPORT_SYMBOL(BpGetRtsCtsUartGpios);
-+EXPORT_SYMBOL(BpGetAdslLedGpio);
-+EXPORT_SYMBOL(BpGetAdslFailLedGpio);
-+EXPORT_SYMBOL(BpGetWirelessLedGpio);
-+EXPORT_SYMBOL(BpGetUsbLedGpio);
-+EXPORT_SYMBOL(BpGetHpnaLedGpio);
-+EXPORT_SYMBOL(BpGetWanDataLedGpio);
-+EXPORT_SYMBOL(BpGetPppLedGpio);
-+EXPORT_SYMBOL(BpGetPppFailLedGpio);
-+EXPORT_SYMBOL(BpGetVoipLedGpio);
-+EXPORT_SYMBOL(BpGetWirelessExtIntr);
-+EXPORT_SYMBOL(BpGetAdslDyingGaspExtIntr);
-+EXPORT_SYMBOL(BpGetVoipExtIntr);
-+EXPORT_SYMBOL(BpGetHpnaExtIntr);
-+EXPORT_SYMBOL(BpGetHpnaChipSelect);
-+EXPORT_SYMBOL(BpGetVoipChipSelect);
-+EXPORT_SYMBOL(BpGetWirelessSesBtnGpio);
-+EXPORT_SYMBOL(BpGetWirelessSesExtIntr);
-+EXPORT_SYMBOL(BpGetWirelessSesLedGpio);
-+EXPORT_SYMBOL(kerSysRegisterDyingGaspHandler);
-+EXPORT_SYMBOL(kerSysDeregisterDyingGaspHandler);
-+EXPORT_SYMBOL(kerSysGetCycleCount);
-+EXPORT_SYMBOL(kerSysSetWdTimer);
-+EXPORT_SYMBOL(kerSysWakeupMonitorTask);
-+
-diff -urN linux-2.6.17/arch/mips/brcm-boards/bcm963xx/boardparms.c linux-2.6.17-brcm63xx/arch/mips/brcm-boards/bcm963xx/boardparms.c
---- linux-2.6.17/arch/mips/brcm-boards/bcm963xx/boardparms.c 1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.6.17-brcm63xx/arch/mips/brcm-boards/bcm963xx/boardparms.c 2006-07-13 19:11:33.000000000 +0200
-@@ -0,0 +1,2391 @@
-+/*
-+<:copyright-gpl
-+
-+ Copyright 2003 Broadcom Corp. All Rights Reserved.
-+
-+ This program is free software; you can distribute it and/or modify it
-+ under the terms of the GNU General Public License (Version 2) as
-+ published by the Free Software Foundation.
-+
-+ This program is distributed in the hope it will be useful, but WITHOUT
-+ ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
-+ FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
-+ for more details.
-+
-+ You should have received a copy of the GNU General Public License along
-+ with this program; if not, write to the Free Software Foundation, Inc.,
-+ 59 Temple Place - Suite 330, Boston MA 02111-1307, USA.
-+
-+:>
-+*/
-+/**************************************************************************
-+ * File Name : boardparms.c
-+ *
-+ * Description: This file contains the implementation for the BCM63xx board
-+ * parameter access functions.
-+ *
-+ * Updates : 07/14/2003 Created.
-+ ***************************************************************************/
-+
-+/* Includes. */
-+#include "boardparms.h"
-+
-+/* Defines. */
-+
-+/* Default psi size in K bytes */
-+#define BP_PSI_DEFAULT_SIZE 24
-+
-+/* Typedefs */
-+typedef struct boardparameters
-+{
-+ char szBoardId[BP_BOARD_ID_LEN]; /* board id string */
-+ ETHERNET_MAC_INFO EnetMacInfos[BP_MAX_ENET_MACS];
-+ VOIP_DSP_INFO VoIPDspInfo[BP_MAX_VOIP_DSP];
-+ unsigned short usSdramSize; /* SDRAM size and type */
-+ unsigned short usPsiSize; /* persistent storage in K bytes */
-+ unsigned short usGpioRj11InnerPair; /* GPIO pin or not defined */
-+ unsigned short usGpioRj11OuterPair; /* GPIO pin or not defined */
-+ unsigned short usGpioPressAndHoldReset; /* GPIO pin or not defined */
-+ unsigned short usGpioPcmciaReset; /* GPIO pin or not defined */
-+ unsigned short usGpioUartRts; /* GPIO pin or not defined */
-+ unsigned short usGpioUartCts; /* GPIO pin or not defined */
-+ unsigned short usGpioLedAdsl; /* GPIO pin or not defined */
-+ unsigned short usGpioLedAdslFail; /* GPIO pin or not defined */
-+ unsigned short usGpioLedWireless; /* GPIO pin or not defined */
-+ unsigned short usGpioLedUsb; /* GPIO pin or not defined */
-+ unsigned short usGpioLedHpna; /* GPIO pin or not defined */
-+ unsigned short usGpioLedWanData; /* GPIO pin or not defined */
-+ unsigned short usGpioLedPpp; /* GPIO pin or not defined */
-+ unsigned short usGpioLedPppFail; /* GPIO pin or not defined */
-+ unsigned short usGpioLedBlPowerOn; /* GPIO pin or not defined */
-+ unsigned short usGpioLedBlAlarm; /* GPIO pin or not defined */
-+ unsigned short usGpioLedBlResetCfg; /* GPIO pin or not defined */
-+ unsigned short usGpioLedBlStop; /* GPIO pin or not defined */
-+ unsigned short usExtIntrWireless; /* ext intr or not defined */
-+ unsigned short usExtIntrAdslDyingGasp; /* ext intr or not defined */
-+ unsigned short usExtIntrHpna; /* ext intr or not defined */
-+ unsigned short usCsHpna; /* chip select not defined */
-+ unsigned short usAntInUseWireless; /* antenna in use or not defined */
-+ unsigned short usGpioSesBtnWireless; /* GPIO pin or not defined */
-+ unsigned short usExtIntrSesBtnWireless; /* ext intr or not defined */
-+ unsigned short usGpioLedSesWireless; /* GPIO pin or not defined */
-+} BOARD_PARAMETERS, *PBOARD_PARAMETERS;
-+
-+/* Variables */
-+#if defined(_BCM96338_) || defined(CONFIG_BCM96338)
-+static BOARD_PARAMETERS g_bcm96338sv =
-+{
-+ "96338SV", /* szBoardId */
-+ {{BP_ENET_INTERNAL_PHY, /* ucPhyType */
-+ 0x01, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x01, /* numSwitchPorts */
-+ BP_ENET_CONFIG_MDIO, /* usConfigType */
-+ BP_NOT_DEFINED}, /* usReverseMii */
-+ {BP_ENET_NO_PHY}}, /* ucPhyType */
-+ {{BP_VOIP_NO_DSP}, /* ucDspType */
-+ {BP_VOIP_NO_DSP}}, /* ucDspType */
-+ BP_MEMORY_16MB_1_CHIP, /* usSdramSize */
-+ BP_PSI_DEFAULT_SIZE, /* usPsiSize */
-+ BP_NOT_DEFINED, /* usGpioRj11InnerPair */
-+ BP_NOT_DEFINED, /* usGpioRj11OuterPair */
-+ BP_NOT_DEFINED, /* usGpioPressAndHoldReset */
-+ BP_NOT_DEFINED, /* usGpioPcmciaReset */
-+ BP_NOT_DEFINED, /* usGpioUartRts */
-+ BP_NOT_DEFINED, /* usGpioUartCts */
-+ BP_NOT_DEFINED, /* usGpioLedAdsl */
-+ BP_NOT_DEFINED, /* usGpioLedAdslFail */
-+ BP_NOT_DEFINED, /* usGpioLedWireless */
-+ BP_NOT_DEFINED, /* usGpioLedUsb */
-+ BP_NOT_DEFINED, /* usGpioLedHpna */
-+ BP_NOT_DEFINED, /* usGpioLedWanData */
-+ BP_NOT_DEFINED, /* usGpioLedPpp */
-+ BP_NOT_DEFINED, /* usGpioLedPppFail */
-+ BP_NOT_DEFINED, /* usGpioLedBlPowerOn */
-+ BP_NOT_DEFINED, /* usGpioLedBlAlarm */
-+ BP_NOT_DEFINED, /* usGpioLedBlResetCfg */
-+ BP_NOT_DEFINED, /* usGpioLedBlStop */
-+ BP_NOT_DEFINED, /* usExtIntrWireless */
-+ BP_HW_DEFINED, /* usExtIntrAdslDyingGasp */
-+ BP_NOT_DEFINED, /* usExtIntrHpna */
-+ BP_NOT_DEFINED, /* usCsHpna */
-+ BP_NOT_DEFINED, /* usAntInUseWireless */
-+ BP_NOT_DEFINED, /* usGpioSesBtnWireless */
-+ BP_NOT_DEFINED, /* usExtIntrSesBtnWireless */
-+ BP_NOT_DEFINED /* usGpioLedSesWireless */
-+};
-+static BOARD_PARAMETERS g_bcm96338l2m8m =
-+{
-+ "96338L-2M-8M", /* szBoardId */
-+ {{BP_ENET_INTERNAL_PHY, /* ucPhyType */
-+ 0x01, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x01, /* numSwitchPorts */
-+ BP_ENET_CONFIG_MDIO, /* usConfigType */
-+ BP_NOT_DEFINED}, /* usReverseMii */
-+ {BP_ENET_NO_PHY}}, /* ucPhyType */
-+ {{BP_VOIP_NO_DSP}, /* ucDspType */
-+ {BP_VOIP_NO_DSP}}, /* ucDspType */
-+ BP_MEMORY_8MB_1_CHIP, /* usSdramSize */
-+ BP_PSI_DEFAULT_SIZE, /* usPsiSize */
-+ BP_NOT_DEFINED, /* usGpioRj11InnerPair */
-+ BP_NOT_DEFINED, /* usGpioRj11OuterPair */
-+ BP_NOT_DEFINED, /* usGpioPressAndHoldReset */
-+ BP_NOT_DEFINED, /* usGpioPcmciaReset */
-+ BP_NOT_DEFINED, /* usGpioUartRts */
-+ BP_NOT_DEFINED, /* usGpioUartCts */
-+ BP_NOT_DEFINED, /* usGpioLedAdsl */
-+ BP_GPIO_2_AL, /* usGpioLedAdslFail */
-+ BP_NOT_DEFINED, /* usGpioLedWireless */
-+ BP_NOT_DEFINED, /* usGpioLedUsb */
-+ BP_NOT_DEFINED, /* usGpioLedHpna */
-+ BP_GPIO_3_AL, /* usGpioLedWanData */
-+ BP_GPIO_3_AL, /* usGpioLedPpp */
-+ BP_GPIO_4_AL, /* usGpioLedPppFail */
-+ BP_GPIO_0_AL, /* usGpioLedBlPowerOn */
-+ BP_NOT_DEFINED, /* usGpioLedBlAlarm */
-+ BP_GPIO_3_AL, /* usGpioLedBlResetCfg */
-+ BP_GPIO_1_AL, /* usGpioLedBlStop */
-+ BP_NOT_DEFINED, /* usExtIntrWireless */
-+ BP_HW_DEFINED, /* usExtIntrAdslDyingGasp */
-+ BP_NOT_DEFINED, /* usExtIntrHpna */
-+ BP_NOT_DEFINED, /* usCsHpna */
-+ BP_NOT_DEFINED, /* usAntInUseWireless */
-+ BP_NOT_DEFINED, /* usGpioSesBtnWireless */
-+ BP_NOT_DEFINED, /* usExtIntrSesBtnWireless */
-+ BP_NOT_DEFINED /* usGpioLedSesWireless */
-+};
-+static PBOARD_PARAMETERS g_BoardParms[] =
-+ {&g_bcm96338sv, &g_bcm96338l2m8m, 0};
-+#endif
-+
-+#if defined(_BCM96345_) || defined(CONFIG_BCM96345)
-+static BOARD_PARAMETERS g_bcm96345r =
-+{
-+ "96345R", /* szBoardId */
-+ {{BP_ENET_INTERNAL_PHY, /* ucPhyType */
-+ 0x01, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x01, /* numSwitchPorts */
-+ BP_ENET_CONFIG_MDIO, /* usConfigType */
-+ BP_NOT_DEFINED}, /* usReverseMii */
-+ {BP_ENET_NO_PHY}}, /* ucPhyType */
-+ {{BP_VOIP_NO_DSP}, /* ucDspType */
-+ {BP_VOIP_NO_DSP}}, /* ucDspType */
-+ BP_MEMORY_8MB_1_CHIP, /* usSdramSize */
-+ BP_PSI_DEFAULT_SIZE, /* usPsiSize */
-+ BP_GPIO_11_AH, /* usGpioRj11InnerPair */
-+ BP_GPIO_12_AH, /* usGpioRj11OuterPair */
-+ BP_GPIO_13_AH, /* usGpioPressAndHoldReset */
-+ BP_NOT_DEFINED, /* usGpioPcmciaReset */
-+ BP_NOT_DEFINED, /* usGpioUartRts */
-+ BP_NOT_DEFINED, /* usGpioUartCts */
-+ BP_GPIO_8_AH, /* usGpioLedAdsl */
-+ BP_NOT_DEFINED, /* usGpioLedAdslFail */
-+ BP_NOT_DEFINED, /* usGpioLedWireless */
-+ BP_NOT_DEFINED, /* usGpioLedUsb */
-+ BP_NOT_DEFINED, /* usGpioLedHpna */
-+ BP_GPIO_8_AH, /* usGpioLedWanData */
-+ BP_GPIO_9_AH, /* usGpioLedPpp */
-+ BP_NOT_DEFINED, /* usGpioLedPppFail */
-+ BP_NOT_DEFINED, /* usGpioLedBlPowerOn */
-+ BP_GPIO_10_AH, /* usGpioLedBlAlarm */
-+ BP_GPIO_9_AH, /* usGpioLedBlResetCfg */
-+ BP_GPIO_8_AH, /* usGpioLedBlStop */
-+ BP_NOT_DEFINED, /* usExtIntrWireless */
-+ BP_EXT_INTR_0, /* usExtIntrAdslDyingGasp */
-+ BP_NOT_DEFINED, /* usExtIntrHpna */
-+ BP_NOT_DEFINED, /* usCsHpna */
-+ BP_NOT_DEFINED, /* usAntInUseWireless */
-+ BP_NOT_DEFINED, /* usGpioSesBtnWireless */
-+ BP_NOT_DEFINED, /* usExtIntrSesBtnWireless */
-+ BP_NOT_DEFINED /* usGpioLedSesWireless */
-+};
-+
-+static BOARD_PARAMETERS g_bcm96345gw2 =
-+{
-+ /* A hardware jumper determines whether GPIO 13 is used for Press and Hold
-+ * Reset or RTS.
-+ */
-+ "96345GW2", /* szBoardId */
-+ {{BP_ENET_EXTERNAL_SWITCH, /* ucPhyType */
-+ 0x00, /* ucPhyAddress */
-+ BP_GPIO_0_AH, /* usGpioPhySpiSck */
-+ BP_GPIO_4_AH, /* usGpioPhySpiSs */
-+ BP_GPIO_12_AH, /* usGpioPhySpiMosi */
-+ BP_GPIO_11_AH, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x04, /* numSwitchPorts */
-+ BP_ENET_CONFIG_GPIO, /* usConfigType */
-+ BP_ENET_REVERSE_MII}, /* usReverseMii */
-+ {BP_ENET_NO_PHY}}, /* ucPhyType */
-+ {{BP_VOIP_DSP, /* ucDspType */
-+ 0x00, /* ucDspAddress */
-+ BP_EXT_INTR_1, /* usExtIntrVoip */
-+ BP_GPIO_6_AH, /* usGpioVoipReset */
-+ BP_GPIO_15_AH, /* usGpioVoipIntr */
-+ BP_NOT_DEFINED, /* usGpioLedVoip */
-+ BP_CS_2}, /* usCsVoip */
-+ {BP_VOIP_NO_DSP}}, /* ucDspType */
-+ BP_MEMORY_16MB_1_CHIP, /* usSdramSize */
-+ BP_PSI_DEFAULT_SIZE, /* usPsiSize */
-+ BP_NOT_DEFINED, /* usGpioRj11InnerPair */
-+ BP_NOT_DEFINED, /* usGpioRj11OuterPair */
-+ BP_GPIO_13_AH, /* usGpioPressAndHoldReset */
-+ BP_GPIO_2_AH, /* usGpioPcmciaReset */
-+ BP_GPIO_13_AH, /* usGpioUartRts */
-+ BP_GPIO_9_AH, /* usGpioUartCts */
-+ BP_GPIO_8_AH, /* usGpioLedAdsl */
-+ BP_NOT_DEFINED, /* usGpioLedAdslFail */
-+ BP_NOT_DEFINED, /* usGpioLedWireless */
-+ BP_GPIO_7_AH, /* usGpioLedUsb */
-+ BP_NOT_DEFINED, /* usGpioLedHpna */
-+ BP_GPIO_8_AH, /* usGpioLedWanData */
-+ BP_NOT_DEFINED, /* usGpioLedPpp */
-+ BP_NOT_DEFINED, /* usGpioLedPppFail */
-+ BP_NOT_DEFINED, /* usGpioLedBlPowerOn */
-+ BP_GPIO_10_AH, /* usGpioLedBlAlarm */
-+ BP_GPIO_7_AH, /* usGpioLedBlResetCfg */
-+ BP_GPIO_8_AH, /* usGpioLedBlStop */
-+ BP_EXT_INTR_2, /* usExtIntrWireless */
-+ BP_EXT_INTR_0, /* usExtIntrAdslDyingGasp */
-+ BP_NOT_DEFINED, /* usExtIntrHpna */
-+ BP_NOT_DEFINED, /* usCsHpna */
-+ BP_WLAN_ANT_MAIN, /* usAntInUseWireless */
-+ BP_NOT_DEFINED, /* usGpioSesBtnWireless */
-+ BP_NOT_DEFINED, /* usExtIntrSesBtnWireless */
-+ BP_NOT_DEFINED /* usGpioLedSesWireless */
-+};
-+
-+static BOARD_PARAMETERS g_bcm96345gw =
-+{
-+ "96345GW", /* szBoardId */
-+ {{BP_ENET_EXTERNAL_SWITCH, /* ucPhyType */
-+ 0x00, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x04, /* numSwitchPorts */
-+ BP_ENET_CONFIG_MDIO, /* usConfigType */
-+ BP_ENET_NO_REVERSE_MII}, /* usReverseMii */
-+ {BP_ENET_NO_PHY}}, /* ucPhyType */
-+ {{BP_VOIP_DSP, /* ucDspType */
-+ 0x00, /* ucDspAddress */
-+ BP_EXT_INTR_1, /* usExtIntrVoip */
-+ BP_GPIO_6_AH, /* usGpioVoipReset */
-+ BP_GPIO_15_AH, /* usGpioVoipIntr */
-+ BP_NOT_DEFINED, /* usGpioLedVoip */
-+ BP_CS_2}, /* usCsVoip */
-+ {BP_VOIP_NO_DSP}}, /* ucDspType */
-+ BP_MEMORY_16MB_1_CHIP, /* usSdramSize */
-+ BP_PSI_DEFAULT_SIZE, /* usPsiSize */
-+ BP_GPIO_11_AH, /* usGpioRj11InnerPair */
-+ BP_GPIO_1_AH, /* usGpioRj11OuterPair */
-+ BP_GPIO_13_AH, /* usGpioPressAndHoldReset */
-+ BP_GPIO_2_AH, /* usGpioPcmciaReset */
-+ BP_NOT_DEFINED, /* usGpioUartRts */
-+ BP_NOT_DEFINED, /* usGpioUartCts */
-+ BP_GPIO_8_AH, /* usGpioLedAdsl */
-+ BP_NOT_DEFINED, /* usGpioLedAdslFail */
-+ BP_GPIO_10_AH, /* usGpioLedWireless */
-+ BP_GPIO_7_AH, /* usGpioLedUsb */
-+ BP_NOT_DEFINED, /* usGpioLedHpna */
-+ BP_GPIO_8_AH, /* usGpioLedWanData */
-+ BP_NOT_DEFINED, /* usGpioLedPpp */
-+ BP_NOT_DEFINED, /* usGpioLedPppFail */
-+ BP_NOT_DEFINED, /* usGpioLedBlPowerOn */
-+ BP_GPIO_9_AH, /* usGpioLedBlAlarm */
-+ BP_GPIO_10_AH, /* usGpioLedBlResetCfg */
-+ BP_GPIO_8_AH, /* usGpioLedBlStop */
-+ BP_EXT_INTR_2, /* usExtIntrWireless */
-+ BP_EXT_INTR_0, /* usExtIntrAdslDyingGasp */
-+ BP_EXT_INTR_3, /* usExtIntrHpna */
-+ BP_CS_1, /* usCsHpna */
-+ BP_WLAN_ANT_MAIN, /* usAntInUseWireless */
-+ BP_NOT_DEFINED, /* usGpioSesBtnWireless */
-+ BP_NOT_DEFINED, /* usExtIntrSesBtnWireless */
-+ BP_NOT_DEFINED /* usGpioLedSesWireless */
-+};
-+
-+static BOARD_PARAMETERS g_bcm96335r =
-+{
-+ "96335R", /* szBoardId */
-+ {{BP_ENET_INTERNAL_PHY, /* ucPhyType */
-+ 0x01, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x01, /* numSwitchPorts */
-+ BP_ENET_CONFIG_MDIO, /* usConfigType */
-+ BP_NOT_DEFINED}, /* usReverseMii */
-+ {BP_ENET_NO_PHY}}, /* ucPhyType */
-+ {{BP_VOIP_NO_DSP}, /* ucDspType */
-+ {BP_VOIP_NO_DSP}}, /* ucDspType */
-+ BP_MEMORY_8MB_1_CHIP, /* usSdramSize */
-+ BP_PSI_DEFAULT_SIZE, /* usPsiSize */
-+ BP_NOT_DEFINED, /* usGpioRj11InnerPair */
-+ BP_NOT_DEFINED, /* usGpioRj11OuterPair */
-+ BP_GPIO_14_AH, /* usGpioPressAndHoldReset */
-+ BP_NOT_DEFINED, /* usGpioPcmciaReset */
-+ BP_NOT_DEFINED, /* usGpioUartRts */
-+ BP_NOT_DEFINED, /* usGpioUartCts */
-+ BP_GPIO_9_AH, /* usGpioLedAdsl */
-+ BP_NOT_DEFINED, /* usGpioLedAdslFail */
-+ BP_NOT_DEFINED, /* usGpioLedWireless */
-+ BP_NOT_DEFINED, /* usGpioLedUsb */
-+ BP_NOT_DEFINED, /* usGpioLedHpna */
-+ BP_GPIO_9_AH, /* usGpioLedWanData */
-+ BP_GPIO_8_AH, /* usGpioLedPpp */
-+ BP_NOT_DEFINED, /* usGpioLedPppFail */
-+ BP_NOT_DEFINED, /* usGpioLedBlPowerOn */
-+ BP_GPIO_10_AH, /* usGpioLedBlAlarm */
-+ BP_GPIO_8_AH, /* usGpioLedBlResetCfg */
-+ BP_GPIO_9_AH, /* usGpioLedBlStop */
-+ BP_NOT_DEFINED, /* usExtIntrWireless */
-+ BP_NOT_DEFINED, /* usExtIntrAdslDyingGasp */
-+ BP_NOT_DEFINED, /* usExtIntrHpna */
-+ BP_NOT_DEFINED, /* usCsHpna */
-+ BP_NOT_DEFINED, /* usAntInUseWireless */
-+ BP_NOT_DEFINED, /* usGpioSesBtnWireless */
-+ BP_NOT_DEFINED, /* usExtIntrSesBtnWireless */
-+ BP_NOT_DEFINED /* usGpioLedSesWireless */
-+};
-+
-+static BOARD_PARAMETERS g_bcm96345r0 =
-+{
-+ "96345R0", /* szBoardId */
-+ {{BP_ENET_INTERNAL_PHY, /* ucPhyType */
-+ 0x01, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x01, /* numSwitchPorts */
-+ BP_ENET_CONFIG_MDIO, /* usConfigType */
-+ BP_NOT_DEFINED}, /* usReverseMii */
-+ {BP_ENET_NO_PHY}}, /* ucPhyType */
-+ {{BP_VOIP_NO_DSP}, /* ucDspType */
-+ {BP_VOIP_NO_DSP}}, /* ucDspType */
-+ BP_MEMORY_8MB_1_CHIP, /* usSdramSize */
-+ BP_PSI_DEFAULT_SIZE, /* usPsiSize */
-+ BP_NOT_DEFINED, /* usGpioRj11InnerPair */
-+ BP_NOT_DEFINED, /* usGpioRj11OuterPair */
-+ BP_NOT_DEFINED, /* usGpioPressAndHoldReset */
-+ BP_NOT_DEFINED, /* usGpioPcmciaReset */
-+ BP_NOT_DEFINED, /* usGpioUartRts */
-+ BP_NOT_DEFINED, /* usGpioUartCts */
-+ BP_GPIO_8_AH, /* usGpioLedAdsl */
-+ BP_NOT_DEFINED, /* usGpioLedAdslFail */
-+ BP_NOT_DEFINED, /* usGpioLedWireless */
-+ BP_NOT_DEFINED, /* usGpioLedUsb */
-+ BP_NOT_DEFINED, /* usGpioLedHpna */
-+ BP_GPIO_9_AH, /* usGpioLedWanData */
-+ BP_GPIO_9_AH, /* usGpioLedPpp */
-+ BP_NOT_DEFINED, /* usGpioLedPppFail */
-+ BP_NOT_DEFINED, /* usGpioLedBlPowerOn */
-+ BP_GPIO_9_AH, /* usGpioLedBlAlarm */
-+ BP_GPIO_8_AH, /* usGpioLedBlResetCfg */
-+ BP_GPIO_8_AH, /* usGpioLedBlStop */
-+ BP_NOT_DEFINED, /* usExtIntrWireless */
-+ BP_NOT_DEFINED, /* usExtIntrAdslDyingGasp */
-+ BP_NOT_DEFINED, /* usExtIntrHpna */
-+ BP_NOT_DEFINED, /* usCsHpna */
-+ BP_NOT_DEFINED, /* usAntInUseWireless */
-+ BP_NOT_DEFINED, /* usGpioSesBtnWireless */
-+ BP_NOT_DEFINED, /* usExtIntrSesBtnWireless */
-+ BP_NOT_DEFINED /* usGpioLedSesWireless */
-+};
-+
-+static BOARD_PARAMETERS g_bcm96345rs =
-+{
-+ "96345RS", /* szBoardId */
-+ {{BP_ENET_EXTERNAL_SWITCH, /* ucPhyType */
-+ 0x00, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x01, /* numSwitchPorts */
-+ BP_ENET_CONFIG_MDIO, /* usConfigType */
-+ BP_ENET_NO_REVERSE_MII}, /* usReverseMii */
-+ {BP_ENET_NO_PHY}}, /* ucPhyType */
-+ {{BP_VOIP_NO_DSP}, /* ucDspType */
-+ {BP_VOIP_NO_DSP}}, /* ucDspType */
-+ BP_MEMORY_8MB_1_CHIP, /* usSdramSize */
-+ BP_PSI_DEFAULT_SIZE, /* usPsiSize */
-+ BP_GPIO_11_AH, /* usGpioRj11InnerPair */
-+ BP_GPIO_12_AH, /* usGpioRj11OuterPair */
-+ BP_GPIO_13_AH, /* usGpioPressAndHoldReset */
-+ BP_NOT_DEFINED, /* usGpioPcmciaReset */
-+ BP_NOT_DEFINED, /* usGpioUartRts */
-+ BP_NOT_DEFINED, /* usGpioUartCts */
-+ BP_GPIO_8_AH, /* usGpioLedAdsl */
-+ BP_NOT_DEFINED, /* usGpioLedAdslFail */
-+ BP_NOT_DEFINED, /* usGpioLedWireless */
-+ BP_NOT_DEFINED, /* usGpioLedUsb */
-+ BP_NOT_DEFINED, /* usGpioLedHpna */
-+ BP_GPIO_8_AH, /* usGpioLedWanData */
-+ BP_GPIO_9_AH, /* usGpioLedPpp */
-+ BP_NOT_DEFINED, /* usGpioLedPppFail */
-+ BP_NOT_DEFINED, /* usGpioLedBlPowerOn */
-+ BP_GPIO_10_AH, /* usGpioLedBlAlarm */
-+ BP_GPIO_9_AH, /* usGpioLedBlResetCfg */
-+ BP_GPIO_8_AH, /* usGpioLedBlStop */
-+ BP_NOT_DEFINED, /* usExtIntrWireless */
-+ BP_EXT_INTR_0, /* usExtIntrAdslDyingGasp */
-+ BP_NOT_DEFINED, /* usExtIntrHpna */
-+ BP_NOT_DEFINED, /* usCsHpna */
-+ BP_NOT_DEFINED, /* usAntInUseWireless */
-+ BP_NOT_DEFINED, /* usGpioSesBtnWireless */
-+ BP_NOT_DEFINED, /* usExtIntrSesBtnWireless */
-+ BP_NOT_DEFINED /* usGpioLedSesWireless */
-+};
-+
-+static PBOARD_PARAMETERS g_BoardParms[] =
-+ {&g_bcm96345r, &g_bcm96345gw2, &g_bcm96345gw, &g_bcm96335r, &g_bcm96345r0,
-+ &g_bcm96345rs, 0};
-+#endif
-+
-+#if defined(_BCM96348_) || defined(CONFIG_BCM96348)
-+
-+static BOARD_PARAMETERS g_bcm96348r =
-+{
-+ "96348R", /* szBoardId */
-+ {{BP_ENET_INTERNAL_PHY, /* ucPhyType */
-+ 0x01, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x01, /* numSwitchPorts */
-+ BP_ENET_CONFIG_MDIO, /* usConfigType */
-+ BP_NOT_DEFINED}, /* usReverseMii */
-+ {BP_ENET_NO_PHY}}, /* ucPhyType */
-+ {{BP_VOIP_NO_DSP}, /* ucDspType */
-+ {BP_VOIP_NO_DSP}}, /* ucDspType */
-+ BP_MEMORY_8MB_1_CHIP, /* usSdramSize */
-+ BP_PSI_DEFAULT_SIZE, /* usPsiSize */
-+ BP_NOT_DEFINED, /* usGpioRj11InnerPair */
-+ BP_NOT_DEFINED, /* usGpioRj11OuterPair */
-+ BP_GPIO_7_AH, /* usGpioPressAndHoldReset */
-+ BP_NOT_DEFINED, /* usGpioPcmciaReset */
-+ BP_NOT_DEFINED, /* usGpioUartRts */
-+ BP_NOT_DEFINED, /* usGpioUartCts */
-+ BP_NOT_DEFINED, /* usGpioLedAdsl */
-+ BP_GPIO_2_AL, /* usGpioLedAdslFail */
-+ BP_NOT_DEFINED, /* usGpioLedWireless */
-+ BP_NOT_DEFINED, /* usGpioLedUsb */
-+ BP_NOT_DEFINED, /* usGpioLedHpna */
-+ BP_GPIO_3_AL, /* usGpioLedWanData */
-+ BP_GPIO_3_AL, /* usGpioLedPpp */
-+ BP_GPIO_4_AL, /* usGpioLedPppFail */
-+ BP_GPIO_0_AL, /* usGpioLedBlPowerOn */
-+ BP_NOT_DEFINED, /* usGpioLedBlAlarm */
-+ BP_GPIO_3_AL, /* usGpioLedBlResetCfg */
-+ BP_GPIO_1_AL, /* usGpioLedBlStop */
-+ BP_NOT_DEFINED, /* usExtIntrWireless */
-+ BP_HW_DEFINED, /* usExtIntrAdslDyingGasp */
-+ BP_NOT_DEFINED, /* usExtIntrHpna */
-+ BP_NOT_DEFINED, /* usCsHpna */
-+ BP_NOT_DEFINED, /* usAntInUseWireless */
-+ BP_NOT_DEFINED, /* usGpioSesBtnWireless */
-+ BP_NOT_DEFINED, /* usExtIntrSesBtnWireless */
-+ BP_NOT_DEFINED /* usGpioLedSesWireless */
-+};
-+
-+static BOARD_PARAMETERS g_bcm96348lv =
-+{
-+ "96348LV", /* szBoardId */
-+ {{BP_ENET_INTERNAL_PHY, /* ucPhyType */
-+ 0x01, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x01, /* numSwitchPorts */
-+ BP_ENET_CONFIG_MDIO, /* usConfigType */
-+ BP_NOT_DEFINED}, /* usReverseMii */
-+ {BP_ENET_EXTERNAL_PHY, /* ucPhyType */
-+ 0x02, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_GPIO_5_AL, /* usGpioPhyReset */
-+ 0x01, /* numSwitchPorts */
-+ BP_ENET_CONFIG_MDIO, /* usConfigType */
-+ BP_NOT_DEFINED}}, /* usReverseMii */
-+ {{BP_VOIP_NO_DSP}, /* ucDspType */
-+ {BP_VOIP_NO_DSP}}, /* ucDspType */
-+ BP_MEMORY_16MB_2_CHIP, /* usSdramSize */
-+ BP_PSI_DEFAULT_SIZE, /* usPsiSize */
-+ BP_NOT_DEFINED, /* usGpioRj11InnerPair */
-+ BP_NOT_DEFINED, /* usGpioRj11OuterPair */
-+ BP_GPIO_7_AH, /* usGpioPressAndHoldReset */
-+ BP_NOT_DEFINED, /* usGpioPcmciaReset */
-+ BP_NOT_DEFINED, /* usGpioUartRts */
-+ BP_NOT_DEFINED, /* usGpioUartCts */
-+ BP_NOT_DEFINED, /* usGpioLedAdsl */
-+ BP_GPIO_2_AL, /* usGpioLedAdslFail */
-+ BP_NOT_DEFINED, /* usGpioLedWireless */
-+ BP_NOT_DEFINED, /* usGpioLedUsb */
-+ BP_NOT_DEFINED, /* usGpioLedHpna */
-+ BP_GPIO_3_AL, /* usGpioLedWanData */
-+ BP_GPIO_3_AL, /* usGpioLedPpp */
-+ BP_GPIO_4_AL, /* usGpioLedPppFail */
-+ BP_GPIO_0_AL, /* usGpioLedBlPowerOn */
-+ BP_NOT_DEFINED, /* usGpioLedBlAlarm */
-+ BP_GPIO_3_AL, /* usGpioLedBlResetCfg */
-+ BP_GPIO_1_AL, /* usGpioLedBlStop */
-+ BP_NOT_DEFINED, /* usExtIntrWireless */
-+ BP_NOT_DEFINED, /* usExtIntrAdslDyingGasp */
-+ BP_NOT_DEFINED, /* usExtIntrHpna */
-+ BP_NOT_DEFINED, /* usCsHpna */
-+ BP_NOT_DEFINED, /* usAntInUseWireless */
-+ BP_NOT_DEFINED, /* usGpioSesBtnWireless */
-+ BP_NOT_DEFINED, /* usExtIntrSesBtnWireless */
-+ BP_NOT_DEFINED /* usGpioLedSesWireless */
-+};
-+
-+static BOARD_PARAMETERS g_bcm96348gw =
-+{
-+ "96348GW", /* szBoardId */
-+ {{BP_ENET_INTERNAL_PHY, /* ucPhyType */
-+ 0x01, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x01, /* numSwitchPorts */
-+ BP_ENET_CONFIG_MDIO, /* usConfigType */
-+ BP_NOT_DEFINED}, /* usReverseMii */
-+ {BP_ENET_EXTERNAL_SWITCH, /* ucPhyType */
-+ 0x00, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x03, /* numSwitchPorts */
-+ BP_ENET_CONFIG_SPI_SSB_0, /* usConfigType */
-+ BP_ENET_REVERSE_MII}}, /* usReverseMii */
-+ {{BP_VOIP_DSP, /* ucDspType */
-+ 0x00, /* ucDspAddress */
-+ BP_EXT_INTR_2, /* usExtIntrVoip */
-+ BP_GPIO_6_AH, /* usGpioVoipReset */
-+ BP_GPIO_34_AH, /* usGpioVoipIntr */
-+ BP_NOT_DEFINED, /* usGpioLedVoip */
-+ BP_CS_2}, /* usCsVoip */
-+ {BP_VOIP_NO_DSP}}, /* ucDspType */
-+ BP_MEMORY_16MB_2_CHIP, /* usSdramSize */
-+ BP_PSI_DEFAULT_SIZE, /* usPsiSize */
-+ BP_NOT_DEFINED, /* usGpioRj11InnerPair */
-+ BP_NOT_DEFINED, /* usGpioRj11OuterPair */
-+ BP_GPIO_33_AL, /* usGpioPressAndHoldReset */
-+ BP_NOT_DEFINED, /* usGpioPcmciaReset */
-+ BP_NOT_DEFINED, /* usGpioUartRts */
-+ BP_NOT_DEFINED, /* usGpioUartCts */
-+ BP_NOT_DEFINED, /* usGpioLedAdsl */
-+ BP_GPIO_2_AL, /* usGpioLedAdslFail */
-+ BP_NOT_DEFINED, /* usGpioLedWireless */
-+ BP_NOT_DEFINED, /* usGpioLedUsb */
-+ BP_NOT_DEFINED, /* usGpioLedHpna */
-+ BP_GPIO_3_AL, /* usGpioLedWanData */
-+ BP_GPIO_3_AL, /* usGpioLedPpp */
-+ BP_GPIO_4_AL, /* usGpioLedPppFail */
-+ BP_GPIO_0_AL, /* usGpioLedBlPowerOn */
-+ BP_NOT_DEFINED, /* usGpioLedBlAlarm */
-+ BP_GPIO_3_AL, /* usGpioLedBlResetCfg */
-+ BP_GPIO_1_AL, /* usGpioLedBlStop */
-+ BP_NOT_DEFINED, /* usExtIntrWireless */
-+ BP_HW_DEFINED, /* usExtIntrAdslDyingGasp */
-+ BP_NOT_DEFINED, /* usExtIntrHpna */
-+ BP_NOT_DEFINED, /* usCsHpna */
-+ BP_WLAN_ANT_MAIN, /* usAntInUseWireless */
-+ BP_NOT_DEFINED, /* BP_GPIO_35_AH, */ /* usGpioSesBtnWireless */
-+ BP_NOT_DEFINED, /* BP_EXT_INTR_3, */ /* usExtIntrSesBtnWireless */
-+ BP_NOT_DEFINED /* BP_GPIO_0_AL */ /* usGpioLedSesWireless */
-+};
-+
-+
-+static BOARD_PARAMETERS g_bcm96348gw_10 =
-+{
-+ "96348GW-10", /* szBoardId */
-+ {{BP_ENET_INTERNAL_PHY, /* ucPhyType */
-+ 0x01, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x01, /* numSwitchPorts */
-+ BP_ENET_CONFIG_MDIO, /* usConfigType */
-+ BP_NOT_DEFINED}, /* usReverseMii */
-+ {BP_ENET_EXTERNAL_SWITCH, /* ucPhyType */
-+ 0x00, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x03, /* numSwitchPorts */
-+ BP_ENET_CONFIG_SPI_SSB_1, /* usConfigType */
-+ BP_ENET_REVERSE_MII}}, /* usReverseMii */
-+ {{BP_VOIP_DSP, /* ucDspType */
-+ 0x00, /* ucDspAddress */
-+ BP_EXT_INTR_2, /* usExtIntrVoip */
-+ BP_GPIO_6_AH, /* usGpioVoipReset */
-+ BP_GPIO_34_AH, /* usGpioVoipIntr */
-+ BP_NOT_DEFINED, /* usGpioLedVoip */
-+ BP_CS_2}, /* usCsVoip */
-+ {BP_VOIP_NO_DSP}}, /* ucDspType */
-+ BP_MEMORY_16MB_2_CHIP, /* usSdramSize */
-+ BP_PSI_DEFAULT_SIZE, /* usPsiSize */
-+ BP_NOT_DEFINED, /* usGpioRj11InnerPair */
-+ BP_NOT_DEFINED, /* usGpioRj11OuterPair */
-+ BP_GPIO_33_AL, /* usGpioPressAndHoldReset */
-+ BP_NOT_DEFINED, /* usGpioPcmciaReset */
-+ BP_NOT_DEFINED, /* usGpioUartRts */
-+ BP_NOT_DEFINED, /* usGpioUartCts */
-+ BP_NOT_DEFINED, /* usGpioLedAdsl */
-+ BP_GPIO_2_AL, /* usGpioLedAdslFail */
-+ BP_NOT_DEFINED, /* usGpioLedWireless */
-+ BP_NOT_DEFINED, /* usGpioLedUsb */
-+ BP_NOT_DEFINED, /* usGpioLedHpna */
-+ BP_GPIO_3_AL, /* usGpioLedWanData */
-+ BP_GPIO_3_AL, /* usGpioLedPpp */
-+ BP_GPIO_4_AL, /* usGpioLedPppFail */
-+ BP_GPIO_0_AL, /* usGpioLedBlPowerOn */
-+ BP_NOT_DEFINED, /* usGpioLedBlAlarm */
-+ BP_GPIO_3_AL, /* usGpioLedBlResetCfg */
-+ BP_GPIO_1_AL, /* usGpioLedBlStop */
-+ BP_NOT_DEFINED, /* usExtIntrWireless */
-+ BP_HW_DEFINED, /* usExtIntrAdslDyingGasp */
-+ BP_NOT_DEFINED, /* usExtIntrHpna */
-+ BP_NOT_DEFINED, /* usCsHpna */
-+ BP_WLAN_ANT_MAIN, /* usAntInUseWireless */
-+ BP_NOT_DEFINED, /* usGpioSesBtnWireless */
-+ BP_NOT_DEFINED, /* usExtIntrSesBtnWireless */
-+ BP_NOT_DEFINED /* usGpioLedSesWireless */
-+};
-+
-+static BOARD_PARAMETERS g_bcm96348gw_11 =
-+{
-+ "96348GW-11", /* szBoardId */
-+ {{BP_ENET_NO_PHY}, /* ucPhyType */
-+ {BP_ENET_EXTERNAL_SWITCH, /* ucPhyType */
-+ 0x00, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x04, /* numSwitchPorts */
-+ BP_ENET_CONFIG_SPI_SSB_1, /* usConfigType */
-+ BP_ENET_REVERSE_MII}}, /* usReverseMii */
-+ {{BP_VOIP_NO_DSP}, /* ucDspType */
-+ {BP_VOIP_NO_DSP}}, /* ucDspType */
-+ BP_MEMORY_16MB_2_CHIP, /* usSdramSize */
-+ BP_PSI_DEFAULT_SIZE, /* usPsiSize */
-+ BP_NOT_DEFINED, /* usGpioRj11InnerPair */
-+ BP_NOT_DEFINED, /* usGpioRj11OuterPair */
-+ BP_GPIO_33_AL, /* usGpioPressAndHoldReset */
-+ BP_NOT_DEFINED, /* usGpioPcmciaReset */
-+ BP_NOT_DEFINED, /* usGpioUartRts */
-+ BP_NOT_DEFINED, /* usGpioUartCts */
-+ BP_NOT_DEFINED, /* usGpioLedAdsl */
-+ BP_GPIO_2_AL, /* usGpioLedAdslFail */
-+ BP_NOT_DEFINED, /* usGpioLedWireless */
-+ BP_NOT_DEFINED, /* usGpioLedUsb */
-+ BP_NOT_DEFINED, /* usGpioLedHpna */
-+ BP_GPIO_3_AL, /* usGpioLedWanData */
-+ BP_GPIO_3_AL, /* usGpioLedPpp */
-+ BP_GPIO_4_AL, /* usGpioLedPppFail */
-+ BP_GPIO_0_AL, /* usGpioLedBlPowerOn */
-+ BP_NOT_DEFINED, /* usGpioLedBlAlarm */
-+ BP_GPIO_3_AL, /* usGpioLedBlResetCfg */
-+ BP_GPIO_1_AL, /* usGpioLedBlStop */
-+ BP_NOT_DEFINED, /* usExtIntrWireless */
-+ BP_HW_DEFINED, /* usExtIntrAdslDyingGasp */
-+ BP_NOT_DEFINED, /* usExtIntrHpna */
-+ BP_NOT_DEFINED, /* usCsHpna */
-+ BP_NOT_DEFINED, /* usAntInUseWireless */
-+ BP_NOT_DEFINED, /* usGpioSesBtnWireless */
-+ BP_NOT_DEFINED, /* usExtIntrSesBtnWireless */
-+ BP_NOT_DEFINED /* usGpioLedSesWireless */
-+};
-+
-+static BOARD_PARAMETERS g_bcm96348sv =
-+{
-+ "96348SV", /* szBoardId */
-+ {{BP_ENET_INTERNAL_PHY, /* ucPhyType */
-+ 0x01, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x01, /* numSwitchPorts */
-+ BP_ENET_CONFIG_MDIO, /* usConfigType */
-+ BP_NOT_DEFINED}, /* usReverseMii */
-+ {BP_ENET_EXTERNAL_PHY, /* ucPhyType */
-+ 0x1f, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x01, /* numSwitchPorts */
-+ BP_ENET_CONFIG_MDIO, /* usConfigType */
-+ BP_NOT_DEFINED}}, /* usReverseMii */
-+ {{BP_VOIP_NO_DSP}, /* ucDspType */
-+ {BP_VOIP_NO_DSP}}, /* ucDspType */
-+ BP_MEMORY_32MB_2_CHIP, /* usSdramSize */
-+ BP_PSI_DEFAULT_SIZE, /* usPsiSize */
-+ BP_NOT_DEFINED, /* usGpioRj11InnerPair */
-+ BP_NOT_DEFINED, /* usGpioRj11OuterPair */
-+ BP_NOT_DEFINED, /* usGpioPressAndHoldReset */
-+ BP_NOT_DEFINED, /* usGpioPcmciaReset */
-+ BP_NOT_DEFINED, /* usGpioUartRts */
-+ BP_NOT_DEFINED, /* usGpioUartCts */
-+ BP_NOT_DEFINED, /* usGpioLedAdsl */
-+ BP_NOT_DEFINED, /* usGpioLedAdslFail */
-+ BP_NOT_DEFINED, /* usGpioLedWireless */
-+ BP_NOT_DEFINED, /* usGpioLedUsb */
-+ BP_NOT_DEFINED, /* usGpioLedHpna */
-+ BP_NOT_DEFINED, /* usGpioLedWanData */
-+ BP_NOT_DEFINED, /* usGpioLedPpp */
-+ BP_NOT_DEFINED, /* usGpioLedPppFail */
-+ BP_NOT_DEFINED, /* usGpioLedBlPowerOn */
-+ BP_NOT_DEFINED, /* usGpioLedBlAlarm */
-+ BP_NOT_DEFINED, /* usGpioLedBlResetCfg */
-+ BP_NOT_DEFINED, /* usGpioLedBlStop */
-+ BP_NOT_DEFINED, /* usExtIntrWireless */
-+ BP_HW_DEFINED, /* usExtIntrAdslDyingGasp */
-+ BP_NOT_DEFINED, /* usExtIntrHpna */
-+ BP_NOT_DEFINED, /* usCsHpna */
-+ BP_NOT_DEFINED, /* usAntInUseWireless */
-+ BP_NOT_DEFINED, /* usGpioSesBtnWireless */
-+ BP_NOT_DEFINED, /* usExtIntrSesBtnWireless */
-+ BP_NOT_DEFINED /* usGpioLedSesWireless */
-+};
-+
-+
-+static BOARD_PARAMETERS g_bcm96348gw_dualDsp =
-+{
-+ "96348GW-DualDSP", /* szBoardId */
-+ {{BP_ENET_INTERNAL_PHY, /* ucPhyType */
-+ 0x01, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x01, /* numSwitchPorts */
-+ BP_ENET_CONFIG_MDIO, /* usConfigType */
-+ BP_NOT_DEFINED}, /* usReverseMii */
-+ {BP_ENET_EXTERNAL_SWITCH, /* ucPhyType */
-+ 0x00, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x03, /* numSwitchPorts */
-+ BP_ENET_CONFIG_SPI_SSB_1, /* usConfigType */
-+ BP_ENET_REVERSE_MII}}, /* usReverseMii */
-+ {{BP_VOIP_DSP, /* ucDspType */
-+ 0x00, /* ucDspAddress */
-+ BP_EXT_INTR_2, /* usExtIntrVoip */
-+ BP_UNEQUIPPED, /* usGpioVoipReset */
-+ BP_GPIO_34_AH, /* usGpioVoipIntr */
-+ BP_NOT_DEFINED, /* usGpioLedVoip */
-+ BP_CS_2}, /* usCsVoip */
-+ {BP_VOIP_DSP, /* ucDspType */
-+ 0x01, /* ucDspAddress */
-+ BP_EXT_INTR_3, /* usExtIntrVoip */
-+ BP_UNEQUIPPED , /* usGpioVoipReset */
-+ BP_GPIO_35_AH, /* usGpioVoipIntr */
-+ BP_NOT_DEFINED, /* usGpioLedVoip */
-+ BP_CS_3}}, /* usCsVoip */
-+ BP_MEMORY_16MB_2_CHIP, /* usSdramSize */
-+ BP_PSI_DEFAULT_SIZE, /* usPsiSize */
-+ BP_NOT_DEFINED, /* usGpioRj11InnerPair */
-+ BP_NOT_DEFINED, /* usGpioRj11OuterPair */
-+ BP_GPIO_33_AL, /* usGpioPressAndHoldReset */
-+ BP_NOT_DEFINED, /* usGpioPcmciaReset */
-+ BP_NOT_DEFINED, /* usGpioUartRts */
-+ BP_NOT_DEFINED, /* usGpioUartCts */
-+ BP_NOT_DEFINED, /* usGpioLedAdsl */
-+ BP_GPIO_2_AL, /* usGpioLedAdslFail */
-+ BP_NOT_DEFINED, /* usGpioLedWireless */
-+ BP_NOT_DEFINED, /* usGpioLedUsb */
-+ BP_NOT_DEFINED, /* usGpioLedHpna */
-+ BP_GPIO_3_AL, /* usGpioLedWanData */
-+ BP_GPIO_3_AL, /* usGpioLedPpp */
-+ BP_GPIO_4_AL, /* usGpioLedPppFail */
-+ BP_GPIO_0_AL, /* usGpioLedBlPowerOn */
-+ BP_NOT_DEFINED, /* usGpioLedBlAlarm */
-+ BP_GPIO_3_AL, /* usGpioLedBlResetCfg */
-+ BP_GPIO_1_AL, /* usGpioLedBlStop */
-+ BP_NOT_DEFINED, /* usExtIntrWireless */
-+ BP_HW_DEFINED, /* usExtIntrAdslDyingGasp */
-+ BP_NOT_DEFINED, /* usExtIntrHpna */
-+ BP_NOT_DEFINED, /* usCsHpna */
-+ BP_WLAN_ANT_MAIN, /* usAntInUseWireless */
-+ BP_NOT_DEFINED, /* usGpioSesBtnWireless */
-+ BP_NOT_DEFINED, /* usExtIntrSesBtnWireless */
-+ BP_NOT_DEFINED /* usGpioLedSesWireless */
-+};
-+
-+
-+static BOARD_PARAMETERS g_bcmCustom_01 =
-+{
-+ "BCMCUST_01", /* szBoardId */
-+ {{BP_ENET_INTERNAL_PHY, /* ucPhyType */
-+ 0x01, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x01, /* numSwitchPorts */
-+ BP_ENET_CONFIG_MDIO, /* usConfigType */
-+ BP_NOT_DEFINED}, /* usReverseMii */
-+ {BP_ENET_NO_PHY, /* ucPhyType */
-+ 0x00, /* ucPhyAddress */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSck */
-+ BP_NOT_DEFINED, /* usGpioPhySpiSs */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMosi */
-+ BP_NOT_DEFINED, /* usGpioPhySpiMiso */
-+ BP_NOT_DEFINED, /* usGpioPhyReset */
-+ 0x01, /* numSwitchPorts */
-+ BP_ENET_CONFIG_SPI_SSB_1, /* usConfigType */
-+ BP_ENET_REVERSE_MII}}, /* usReverseMii */
-+ {{BP_VOIP_DSP, /* ucDspType */
-+ 0x00, /* ucDspAddress */
-+ BP_EXT_INTR_2, /* usExtIntrVoip */
-+ BP_GPIO_36_AH, /* usGpioVoipReset */
-+ BP_GPIO_34_AL, /* usGpioVoipIntr */
-+ BP_NOT_DEFINED, /* usGpioLedVoip */
-+ BP_CS_2}, /* usCsVoip */
-+ {BP_VOIP_NO_DSP}}, /* ucDspType */
-+ BP_MEMORY_16MB_2_CHIP, /* usSdramSize */
-+ BP_PSI_DEFAULT_SIZE, /* usPsiSize */
-+ BP_NOT_DEFINED, /* usGpioRj11InnerPair */
-+ BP_NOT_DEFINED, /* usGpioRj11OuterPair */
-+ BP_GPIO_33_AL, /* usGpioPressAndHoldReset */
-+ BP_NOT_DEFINED, /* usGpioPcmciaReset */
-+ BP_NOT_DEFINED, /* usGpioUartRts */
-+ BP_NOT_DEFINED, /* usGpioUartCts */
-+ BP_NOT_DEFINED, /* usGpioLedAdsl */
-+ BP_GPIO_2_AL, /* usGpioLedAdslFail */
-+ BP_NOT_DEFINED, /* usGpioLedWireless */
-+ BP_NOT_DEFINED, /* usGpioLedUsb */
-+ BP_NOT_DEFINED, /* usGpioLedHpna */
-+ BP_GPIO_3_AL, /* usGpioLedWanData */
-+ BP_GPIO_3_AL, /* usGpioLedPpp */
-+ BP_GPIO_4_AL, /* usGpioLedPppFail */
-+ BP_GPIO_0_AL, /* usGpioLedBlPowerOn */
-+ BP_NOT_DEFINED, /* usGpioLedBlAlarm */
-+ BP_GPIO_3_AL, /* usGpioLedBlResetCfg */
-+ BP_GPIO_1_AL, /* usGpioLedBlStop */
-+ BP_NOT_DEFINED, /* usExtIntrWireless */
-+ BP_NOT_DEFINED, /* usExtIntrAdslDyingGasp */
-+ BP_NOT_DEFINED, /* usExtIntrHpna */
-+ BP_NOT_DEFINED, /* usCsHpna */
-+ BP_NOT_DEFINED, /* usAntInUseWireless */
-+ BP_NOT_DEFINED, /* usGpioSesBtnWireless */
-+ BP_NOT_DEFINED, /* usExtIntrSesBtnWireless */
-+ BP_NOT_DEFINED /* usGpioLedSesWireless */
-+};
-+
-+static PBOARD_PARAMETERS g_BoardParms[] =
-+ {&g_bcm96348r, &g_bcm96348lv, &g_bcm96348gw, &g_bcm96348gw_10,
-+ &g_bcm96348gw_11, &g_bcm96348sv, &g_bcm96348gw_dualDsp,
-+ &g_bcmCustom_01, 0};
-+#endif
-+
-+static PBOARD_PARAMETERS g_pCurrentBp = 0;
-+
-+/**************************************************************************
-+ * Name : bpstrcmp
-+ *
-+ * Description: String compare for this file so it does not depend on an OS.