RFI: pinctrl & mcp32s08 driver

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

 



G'day All,

The mcp32s08 driver was recently moved from the drivers/gpio to drivers/pinctlr.

My system (SOCFPGA) doesn't have a pinctrl so it never set kconfig PINCTRL variable.
So I can't get access to enable the new PINCTRL_MCP23S08 variable to enable the driver.

Not sure what I'm supposed to do here. Documentation suggests pinctrl is platform specific,
but the mcp32s08 driver isn't really soc specific being an i2c/spi device.

For testing I've edited the pinctrl/Kconfig to make PINCTRL a menuconfig variable same as GPIOLIB


In addition my hardware has a mcp23017 & mcp23018 sharing an irq line.
So this requires an active low open drain output.
This line is then routed via fpga fabric to the SOCFPGA arm processor generic interrupt input
which only accepts active high inputs. So it's inverted in the fpga fabric.

The mcp23s08 driver in mcp23s08_irq_setup forces the irq flag based on the chip
configuration. Which breaks this.

ie setting IRQ_TYPE_LEVEL_HIGH in the device tree for the mcp irq is effectively ignored.

What's the correct approach here. Shouldn't this just honour the device tree?



Also noticed when compiling the driver in new mcp_pinconf_set()

	case PIN_CONFIG_BIAS_PULL_UP:
		val = arg ? 0xFFFF : 0x0000;
		mask = BIT(pin);
		ret = mcp_set_bit(mcp, MCP_GPPU, pin, arg);
		break;

val & mask aren't used.

I'm not sure which part is the typo.



--
Regards
Phil Reid
--
To unsubscribe from this list: send the line "unsubscribe linux-gpio" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[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