Message ID | e6dc33e399f119e6430bca48223cb2127930939b.1712646750.git.albanhuang@tencent.com |
---|---|
State | Superseded |
Headers | show |
Series | serial: 8250_pnp: Support configurable reg shift property | expand |
Hi Guanbing, kernel test robot noticed the following build errors: [auto build test ERROR on tty/tty-testing] [also build test ERROR on tty/tty-next tty/tty-linus usb/usb-testing usb/usb-next usb/usb-linus linus/master v6.9-rc3 next-20240409] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch#_base_tree_information] url: https://github.com/intel-lab-lkp/linux/commits/Guanbing-Huang/PNP-Add-dev_is_pnp-macro/20240409-154558 base: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty.git tty-testing patch link: https://lore.kernel.org/r/e6dc33e399f119e6430bca48223cb2127930939b.1712646750.git.albanhuang%40tencent.com patch subject: [PATCH v6 2/3] serial: port: Add support of PNP IRQ to __uart_read_properties() config: openrisc-defconfig (https://download.01.org/0day-ci/archive/20240410/202404100523.b06UvPSB-lkp@intel.com/config) compiler: or1k-linux-gcc (GCC) 13.2.0 reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240410/202404100523.b06UvPSB-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@intel.com> | Closes: https://lore.kernel.org/oe-kbuild-all/202404100523.b06UvPSB-lkp@intel.com/ All errors (new ones prefixed by >>): or1k-linux-ld: drivers/tty/serial/serial_port.o: in function `__uart_read_properties': >> serial_port.c:(.text+0x230): undefined reference to `pnp_bus_type' >> or1k-linux-ld: serial_port.c:(.text+0x234): undefined reference to `pnp_bus_type'
diff --git a/drivers/tty/serial/serial_port.c b/drivers/tty/serial/serial_port.c index 22b9eeb23e68..8504bae1d2c9 100644 --- a/drivers/tty/serial/serial_port.c +++ b/drivers/tty/serial/serial_port.c @@ -11,6 +11,7 @@ #include <linux/of.h> #include <linux/platform_device.h> #include <linux/pm_runtime.h> +#include <linux/pnp.h> #include <linux/property.h> #include <linux/serial_core.h> #include <linux/spinlock.h> @@ -221,7 +222,11 @@ static int __uart_read_properties(struct uart_port *port, bool use_defaults) if (dev_is_platform(dev)) ret = platform_get_irq(to_platform_device(dev), 0); - else + else if (dev_is_pnp(dev)) { + ret = pnp_irq(to_pnp_dev(dev), 0); + if (ret < 0) + ret = -ENXIO; + } else ret = fwnode_irq_get(dev_fwnode(dev), 0); if (ret == -EPROBE_DEFER) return ret;