pinctrl: sunxi: sunxi-pinctrl fail to load with CONFIG_DEBUG_TEST_DRIVER_REMOVE
Hello
With CONFIG_DEBUG_TEST_DRIVER_REMOVE=y pinctrl-sunxi fail to load on the second try.
[ 3.900061] sun8i-h3-pinctrl 1c20800.pinctrl: initialized sunXi PIO driver [ 3.916251] gpio gpiochip1: GPIO integer space overlap, cannot add chip [ 3.923016] gpiochip_add_data: GPIOs 0..223 (1c20800.pinctrl) failed to register [ 3.931099] sun8i-h3-pinctrl: probe of 1c20800.pinctrl failed with error -16 [ 3.944709] sun8i-h3-r-pinctrl 1f02c00.pinctrl: initialized sunXi PIO driver [ 3.960796] gpio gpiochip2: GPIO integer space overlap, cannot add chip [ 3.967594] gpiochip_add_data: GPIOs 352..383 (1f02c00.pinctrl) failed to register [ 3.975633] sun8i-h3-r-pinctrl: probe of 1f02c00.pinctrl failed with error -16
Without it, all subsequent drivers fail to load.
Tested on Orange PI PC board.
Regards
Hi,
Quoted 13 lines · LABBE Corentin
Hello
With
CONFIG_DEBUG_TEST_DRIVER_REMOVE=ypinctrl-sunxi fail to load on the second try.[ 3.900061] sun8i-h3-pinctrl 1c20800.pinctrl: initialized sunXi PIO driver [ 3.916251] gpio gpiochip1: GPIO integer space overlap, cannot add chip [ 3.923016] gpiochip_add_data: GPIOs 0..223 (1c20800.pinctrl) failed to register [ 3.931099] sun8i-h3-pinctrl: probe of 1c20800.pinctrl failed with error -16 [ 3.944709] sun8i-h3-r-pinctrl 1f02c00.pinctrl: initialized sunXi PIO driver [ 3.960796] gpio gpiochip2: GPIO integer space overlap, cannot add chip [ 3.967594] gpiochip_add_data: GPIOs 352..383 (1f02c00.pinctrl) failed to register [ 3.975633] sun8i-h3-r-pinctrl: probe of 1f02c00.pinctrl failed with error -16
Quoted 2 lines
Without it, all subsequent drivers fail to load.
Tested on Orange PI PC board.
I don't think the pinctrl drivers were designed to be removed. And I thought the lack of a .remove callback in the driver blocks the core from removing the device? Maybe I remember wrong...
ChenYu
Quoted 2 lines
Regards
Quoted 17 lines · Chen-Yu Tsai
Hi,
Quoted 13 lines · LABBE Corentin
Hello
With
CONFIG_DEBUG_TEST_DRIVER_REMOVE=ypinctrl-sunxi fail to load on the second try.[ 3.900061] sun8i-h3-pinctrl 1c20800.pinctrl: initialized sunXi PIO driver [ 3.916251] gpio gpiochip1: GPIO integer space overlap, cannot add chip [ 3.923016] gpiochip_add_data: GPIOs 0..223 (1c20800.pinctrl) failed to register [ 3.931099] sun8i-h3-pinctrl: probe of 1c20800.pinctrl failed with error -16 [ 3.944709] sun8i-h3-r-pinctrl 1f02c00.pinctrl: initialized sunXi PIO driver [ 3.960796] gpio gpiochip2: GPIO integer space overlap, cannot add chip [ 3.967594] gpiochip_add_data: GPIOs 352..383 (1f02c00.pinctrl) failed to register [ 3.975633] sun8i-h3-r-pinctrl: probe of 1f02c00.pinctrl failed with error -16
Quoted 6 lines
Quoted 2 lines
Without it, all subsequent drivers fail to load.
Tested on Orange PI PC board.I don't think the pinctrl drivers were designed to be removed. And I thought the lack of a .remove callback in the driver blocks the core from removing the device? Maybe I remember wrong...
Using a builtin_platform_driver should be enough to prevent it to be removed.
Maxime
Signature · 10 lines
Maxime Ripard, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 801 bytes Desc: not available URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20161107/862f84d3/attachment.sig>
Quoted 21 lines · Maxime Ripard
Quoted 20 lines · Chen-Yu Tsai
Hi,
Quoted 15 lines · LABBE Corentin
Hello
With
CONFIG_DEBUG_TEST_DRIVER_REMOVE=ypinctrl-sunxi fail to load on the second try.[ 3.900061] sun8i-h3-pinctrl 1c20800.pinctrl: initialized sunXi PIO driver [ 3.916251] gpio gpiochip1: GPIO integer space overlap, cannot add chip [ 3.923016] gpiochip_add_data: GPIOs 0..223 (1c20800.pinctrl) failed to register [ 3.931099] sun8i-h3-pinctrl: probe of 1c20800.pinctrl failed with error -16 [ 3.944709] sun8i-h3-r-pinctrl 1f02c00.pinctrl: initialized sunXi PIO driver [ 3.960796] gpio gpiochip2: GPIO integer space overlap, cannot add chip [ 3.967594] gpiochip_add_data: GPIOs 352..383 (1f02c00.pinctrl) failed to register [ 3.975633] sun8i-h3-r-pinctrl: probe of 1f02c00.pinctrl failed with error -16Without it, all subsequent drivers fail to load.
Tested on Orange PI PC board.
Quoted 6 lines
Quoted 3 lines
I don't think the pinctrl drivers were designed to be removed. And I thought the lack of a .remove callback in the driver blocks the core from removing the device? Maybe I remember wrong...
Using a
builtin_platform_drivershould be enough to prevent it to be removed.
Labbe, can you test it again on linux-next? Or at least with this patch
0c8c6ba00cbf pinctrl: sunxi: make bool drivers explicitly non-modular
from linux-pinctrl applied. This should fix it.
ChenYu
Quoted 21 lines · Maxime Ripard
Quoted 20 lines · Chen-Yu Tsai
Hi,
Quoted 15 lines · LABBE Corentin
Hello
With
CONFIG_DEBUG_TEST_DRIVER_REMOVE=ypinctrl-sunxi fail to load on the second try.[ 3.900061] sun8i-h3-pinctrl 1c20800.pinctrl: initialized sunXi PIO driver [ 3.916251] gpio gpiochip1: GPIO integer space overlap, cannot add chip [ 3.923016] gpiochip_add_data: GPIOs 0..223 (1c20800.pinctrl) failed to register [ 3.931099] sun8i-h3-pinctrl: probe of 1c20800.pinctrl failed with error -16 [ 3.944709] sun8i-h3-r-pinctrl 1f02c00.pinctrl: initialized sunXi PIO driver [ 3.960796] gpio gpiochip2: GPIO integer space overlap, cannot add chip [ 3.967594] gpiochip_add_data: GPIOs 352..383 (1f02c00.pinctrl) failed to register [ 3.975633] sun8i-h3-r-pinctrl: probe of 1f02c00.pinctrl failed with error -16Without it, all subsequent drivers fail to load.
Tested on Orange PI PC board.
Quoted 7 lines
Quoted 3 lines
I don't think the pinctrl drivers were designed to be removed. And I thought the lack of a .remove callback in the driver blocks the core from removing the device? Maybe I remember wrong...
Using a
builtin_platform_drivershould be enough to prevent it to be removed.
The problem is that it is already builtin_platform_driver()
Quoted 26 lines · Corentin Labbe
Quoted 25 lines · Maxime Ripard
Quoted 23 lines · Chen-Yu Tsai
Hi,
Quoted 13 lines · LABBE Corentin
Hello
With
CONFIG_DEBUG_TEST_DRIVER_REMOVE=ypinctrl-sunxi fail to load on the second try.[ 3.900061] sun8i-h3-pinctrl 1c20800.pinctrl: initialized sunXi PIO driver [ 3.916251] gpio gpiochip1: GPIO integer space overlap, cannot add chip [ 3.923016] gpiochip_add_data: GPIOs 0..223 (1c20800.pinctrl) failed to register [ 3.931099] sun8i-h3-pinctrl: probe of 1c20800.pinctrl failed with error -16 [ 3.944709] sun8i-h3-r-pinctrl 1f02c00.pinctrl: initialized sunXi PIO driver [ 3.960796] gpio gpiochip2: GPIO integer space overlap, cannot add chip [ 3.967594] gpiochip_add_data: GPIOs 352..383 (1f02c00.pinctrl) failed to register [ 3.975633] sun8i-h3-r-pinctrl: probe of 1f02c00.pinctrl failed with error -16Quoted 2 lines
Without it, all subsequent drivers fail to load.
Tested on Orange PI PC board.I don't think the pinctrl drivers were designed to be removed. And I thought the lack of a .remove callback in the driver blocks the core from removing the device? Maybe I remember wrong...
Quoted 5 lines
Quoted 3 lines
Using a
builtin_platform_drivershould be enough to prevent it to be removed.The problem is that it is already
builtin_platform_driver()
Then there's no way it can be removed in the first place.
Maxime
Signature · 10 lines
Maxime Ripard, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 801 bytes Desc: not available URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20161107/7d77b907/attachment.sig>
Quoted 27 lines · Maxime Ripard
Quoted 26 lines · Corentin Labbe
Quoted 25 lines · Maxime Ripard
Quoted 23 lines · Chen-Yu Tsai
Hi,
Quoted 13 lines · LABBE Corentin
Hello
With
CONFIG_DEBUG_TEST_DRIVER_REMOVE=ypinctrl-sunxi fail to load on the second try.[ 3.900061] sun8i-h3-pinctrl 1c20800.pinctrl: initialized sunXi PIO driver [ 3.916251] gpio gpiochip1: GPIO integer space overlap, cannot add chip [ 3.923016] gpiochip_add_data: GPIOs 0..223 (1c20800.pinctrl) failed to register [ 3.931099] sun8i-h3-pinctrl: probe of 1c20800.pinctrl failed with error -16 [ 3.944709] sun8i-h3-r-pinctrl 1f02c00.pinctrl: initialized sunXi PIO driver [ 3.960796] gpio gpiochip2: GPIO integer space overlap, cannot add chip [ 3.967594] gpiochip_add_data: GPIOs 352..383 (1f02c00.pinctrl) failed to register [ 3.975633] sun8i-h3-r-pinctrl: probe of 1f02c00.pinctrl failed with error -16Quoted 2 lines
Without it, all subsequent drivers fail to load.
Tested on Orange PI PC board.I don't think the pinctrl drivers were designed to be removed. And I thought the lack of a .remove callback in the driver blocks the core from removing the device? Maybe I remember wrong...
Quoted 8 lines
Quoted 5 lines
Quoted 3 lines
Using a
builtin_platform_drivershould be enough to prevent it to be removed.The problem is that it is already
builtin_platform_driver()Then there's no way it can be removed in the first place.
I will send a patch for fixing CONFIG_DEBUG_TEST_DRIVER_REMOVE