[pinctrl:gpio-driver-h 40/40] drivers/pinctrl//nomadik/pinctrl-nomadik.c:974:19: error: 'struct gpio_chip' has no member named 'gpio_to_irq'; did you mean 'to_irq'?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



tree:   https://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl.git gpio-driver-h
head:   ee99bdd7d44c34d417e43bbcd30199891eacdb21
commit: ee99bdd7d44c34d417e43bbcd30199891eacdb21 [40/40] pinctrl: Include <linux/gpio/driver.h> nothing else
config: arm-multi_v7_defconfig (attached as .config)
compiler: arm-linux-gnueabi-gcc (Debian 7.2.0-11) 7.2.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        git checkout ee99bdd7d44c34d417e43bbcd30199891eacdb21
        # save the attached .config to linux build tree
        GCC_VERSION=7.2.0 make.cross ARCH=arm 

All errors (new ones prefixed by >>):

   drivers/pinctrl//nomadik/pinctrl-nomadik.c: In function 'nmk_gpio_dbg_show_one':
>> drivers/pinctrl//nomadik/pinctrl-nomadik.c:974:19: error: 'struct gpio_chip' has no member named 'gpio_to_irq'; did you mean 'to_irq'?
      int irq = chip->gpio_to_irq(chip, gpio);
                      ^~~~~~~~~~~
                      to_irq

vim +974 drivers/pinctrl//nomadik/pinctrl-nomadik.c

   932	
   933	static void nmk_gpio_dbg_show_one(struct seq_file *s,
   934		struct pinctrl_dev *pctldev, struct gpio_chip *chip,
   935		unsigned offset, unsigned gpio)
   936	{
   937		const char *label = gpiochip_is_requested(chip, offset);
   938		struct nmk_gpio_chip *nmk_chip = gpiochip_get_data(chip);
   939		int mode;
   940		bool is_out;
   941		bool data_out;
   942		bool pull;
   943		const char *modes[] = {
   944			[NMK_GPIO_ALT_GPIO]	= "gpio",
   945			[NMK_GPIO_ALT_A]	= "altA",
   946			[NMK_GPIO_ALT_B]	= "altB",
   947			[NMK_GPIO_ALT_C]	= "altC",
   948			[NMK_GPIO_ALT_C+1]	= "altC1",
   949			[NMK_GPIO_ALT_C+2]	= "altC2",
   950			[NMK_GPIO_ALT_C+3]	= "altC3",
   951			[NMK_GPIO_ALT_C+4]	= "altC4",
   952		};
   953		const char *pulls[] = {
   954			"none     ",
   955			"pull down",
   956			"pull up  ",
   957		};
   958	
   959		clk_enable(nmk_chip->clk);
   960		is_out = !!(readl(nmk_chip->addr + NMK_GPIO_DIR) & BIT(offset));
   961		pull = !(readl(nmk_chip->addr + NMK_GPIO_PDIS) & BIT(offset));
   962		data_out = !!(readl(nmk_chip->addr + NMK_GPIO_DAT) & BIT(offset));
   963		mode = nmk_gpio_get_mode(nmk_chip, offset);
   964		if ((mode == NMK_GPIO_ALT_C) && pctldev)
   965			mode = nmk_prcm_gpiocr_get_mode(pctldev, gpio);
   966	
   967		if (is_out) {
   968			seq_printf(s, " gpio-%-3d (%-20.20s) out %s        %s",
   969				   gpio,
   970				   label ?: "(none)",
   971				   data_out ? "hi" : "lo",
   972				   (mode < 0) ? "unknown" : modes[mode]);
   973		} else {
 > 974			int irq = chip->gpio_to_irq(chip, gpio);
   975			struct irq_desc	*desc = irq_to_desc(irq);
   976			int pullidx = 0;
   977			int val;
   978	
   979			if (pull)
   980				pullidx = data_out ? 2 : 1;
   981	
   982			seq_printf(s, " gpio-%-3d (%-20.20s) in  %s %s",
   983				   gpio,
   984				   label ?: "(none)",
   985				   pulls[pullidx],
   986				   (mode < 0) ? "unknown" : modes[mode]);
   987	
   988			val = nmk_gpio_get_input(chip, offset);
   989			seq_printf(s, " VAL %d", val);
   990	
   991			/*
   992			 * This races with request_irq(), set_irq_type(),
   993			 * and set_irq_wake() ... but those are "rare".
   994			 */
   995			if (irq > 0 && desc && desc->action) {
   996				char *trigger;
   997	
   998				if (nmk_chip->edge_rising & BIT(offset))
   999					trigger = "edge-rising";
  1000				else if (nmk_chip->edge_falling & BIT(offset))
  1001					trigger = "edge-falling";
  1002				else
  1003					trigger = "edge-undefined";
  1004	
  1005				seq_printf(s, " irq-%d %s%s",
  1006					   irq, trigger,
  1007					   irqd_is_wakeup_set(&desc->irq_data)
  1008					   ? " wakeup" : "");
  1009			}
  1010		}
  1011		clk_disable(nmk_chip->clk);
  1012	}
  1013	

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux