[arm:zii 65/76] drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c:487:45: error: 'TXGBE_CFG_PORT_ST_LINK_' undeclared; did you mean 'TXGBE_CFG_PORT_ST_LINK_UP'?

kernel test robot lkp at intel.com
Mon Apr 15 11:51:42 PDT 2024


tree:   git://git.armlinux.org.uk/~rmk/linux-arm.git zii
head:   8a2e4ae480ee76646194828ac4ec8eba9af66fb5
commit: 75f641d7b0fe9198253792c1d470d54e9862e1f8 [65/76] net: txgbe: use phylink_pcs_change() to report PCS link change events
config: loongarch-defconfig (https://download.01.org/0day-ci/archive/20240416/202404160221.gVgbG3YU-lkp@intel.com/config)
compiler: loongarch64-linux-gcc (GCC) 13.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240416/202404160221.gVgbG3YU-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp at intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202404160221.gVgbG3YU-lkp@intel.com/

All errors (new ones prefixed by >>):

   drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c: In function 'txgbe_irq_handler':
>> drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c:487:45: error: 'TXGBE_CFG_PORT_ST_LINK_' undeclared (first use in this function); did you mean 'TXGBE_CFG_PORT_ST_LINK_UP'?
     487 |                                    !!(reg & TXGBE_CFG_PORT_ST_LINK_+UP));
         |                                             ^~~~~~~~~~~~~~~~~~~~~~~
         |                                             TXGBE_CFG_PORT_ST_LINK_UP
   drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c:487:45: note: each undeclared identifier is reported only once for each function it appears in
>> drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c:487:69: error: 'UP' undeclared (first use in this function); did you mean 'up'?
     487 |                                    !!(reg & TXGBE_CFG_PORT_ST_LINK_+UP));
         |                                                                     ^~
         |                                                                     up


vim +487 drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c

   448	
   449	static void txgbe_irq_handler(struct irq_desc *desc)
   450	{
   451		struct irq_chip *chip = irq_desc_get_chip(desc);
   452		struct wx *wx = irq_desc_get_handler_data(desc);
   453		struct txgbe *txgbe = wx->priv;
   454		irq_hw_number_t hwirq;
   455		unsigned long gpioirq;
   456		struct gpio_chip *gc;
   457		unsigned long flags;
   458		u32 eicr;
   459	
   460		eicr = wx_misc_isb(wx, WX_ISB_MISC);
   461	
   462		chained_irq_enter(chip, desc);
   463	
   464		gpioirq = rd32(wx, WX_GPIO_INTSTATUS);
   465	
   466		gc = txgbe->gpio;
   467		for_each_set_bit(hwirq, &gpioirq, gc->ngpio) {
   468			int gpio = irq_find_mapping(gc->irq.domain, hwirq);
   469			u32 irq_type = irq_get_trigger_type(gpio);
   470	
   471			generic_handle_domain_irq(gc->irq.domain, hwirq);
   472	
   473			if ((irq_type & IRQ_TYPE_SENSE_MASK) == IRQ_TYPE_EDGE_BOTH) {
   474				raw_spin_lock_irqsave(&wx->gpio_lock, flags);
   475				txgbe_toggle_trigger(gc, hwirq);
   476				raw_spin_unlock_irqrestore(&wx->gpio_lock, flags);
   477			}
   478		}
   479	
   480		chained_irq_exit(chip, desc);
   481	
   482		if (eicr & (TXGBE_PX_MISC_ETH_LK | TXGBE_PX_MISC_ETH_LKDN |
   483			    TXGBE_PX_MISC_ETH_AN)) {
   484			u32 reg = rd32(wx, TXGBE_CFG_PORT_ST);
   485	
   486			phylink_pcs_change(&txgbe->xpcs->pcs,
 > 487					   !!(reg & TXGBE_CFG_PORT_ST_LINK_+UP));
   488		}
   489	
   490		/* unmask interrupt */
   491		wx_intr_enable(wx, TXGBE_INTR_MISC);
   492	}
   493	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki



More information about the linux-arm-kernel mailing list