pwm-backlight: 3.13-rc1 regression for old arm machine
Hi Thierry,
Since recently, and probable since last Linus's merge of PWM tree (Merge tag 'pwm/for-3.13-rc1' ofgit://git.kernel.org/pub/scm/linux/kernel/git/thierry.reding/linux-pwm), my platform has its backlight broken.
The particularity of my platform:
- arch/arm/mach-pxa/mioa701.c
- no device tree
- no power supply regulator for backlight
- backlight controlled by a PWM
- kernel message :
[ 1.495480] platform pwm-backlight: Driver pwm-backlight requests probe deferral
I think other "old" platforms will suffer from this. Do you have a recommendation ?
Cheers.
--
Robert
Quoted 1 line · Robert Jarzmik
Hi Thierry,
Hi Robert,
Please always Cc the linux-pwm mailing list for PWM related questions. I've done that now.
Quoted 11 lines
Since recently, and probable since last Linus's merge of PWM tree (Merge tag 'pwm/for-3.13-rc1' of
git://git.kernel.org/pub/scm/linux/kernel/git/thierry.reding/linux-pwm), my platform has its backlight broken.The particularity of my platform:
-arch/arm/mach-pxa/mioa701.c
- no device tree
- no power supply regulator for backlight
- backlight controlled by a PWM
- kernel message :
Quoted 4 lines
[ 1.495480] platform pwm-backlight: Driver pwm-backlight requests probe deferralI think other "old" platforms will suffer from this. Do you have a recommendation ?
I hadn't anticipated that =(. In fact I had been holding this patch back for a release cycle because I was waiting for a specific regulator patch to land which provides a dummy regulator if one wasn't specified. It seems that that patch only works when booting from DT, though.
The correct way to fix this would be to provide a lookup table with the dummy regulator in the board file. I've attached a patch (compile-tested only) that might work.
If it does, please let me know and, if nobody else volunteers, I'll see if I can come up with a set of patches to fix this for any other boards that have the same issue.
Thierry
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-ARM-pxa-Add-dummy-power-supply-for-backlight-for-Mit.patch
Type: text/x-diff
Size: 1813 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20131217/194fd6ef/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20131217/194fd6ef/attachment-0001.sig>
Quoted 5 lines · Thierry Reding
I hadn't anticipated that =(. In fact I had been holding this patch back for a release cycle because I was waiting for a specific regulator patch to land which provides a dummy regulator if one wasn't specified. It seems that that patch only works when booting from DT, though.
Quoted 7 lines
The correct way to fix this would be to provide a lookup table with the dummy regulator in the board file. I've attached a patch (compile-tested only) that might work.
If it does, please let me know and, if nobody else volunteers, I'll see if I can come up with a set of patches to fix this for any other boards that have the same issue.
Actually, it needs a very small "tweak" to work :
- REGULATOR_SUPPLY("power", "pwm-backlight.0"),
+ REGULATOR_SUPPLY("power", "pwm-backlight"),
Without it regulator_dev_lookup() won't match the device.
Moreover, it requires a config option, CONFIG_REGULATOR_FIXED_VOLTAGE=y. That's not a problem for my specific platform, but I haven't seen *any* PXA platform with it activated, which means all defconfigs have to be patched, which is unfortunate.
As for my specific mioa701, your change with the tweak is perfectly fine and tested.
Cheers.
--
Robert
Quoted 18 lines · Robert Jarzmik
Quoted 5 lines · Thierry Reding
I hadn't anticipated that =(. In fact I had been holding this patch back for a release cycle because I was waiting for a specific regulator patch to land which provides a dummy regulator if one wasn't specified. It seems that that patch only works when booting from DT, though.
Quoted 7 lines
The correct way to fix this would be to provide a lookup table with the dummy regulator in the board file. I've attached a patch (compile-tested only) that might work.
If it does, please let me know and, if nobody else volunteers, I'll see if I can come up with a set of patches to fix this for any other boards that have the same issue.
Actually, it needs a very small "tweak" to work :
(quoted diff) +1
-1- REGULATOR_SUPPLY("power", "pwm-backlight.0"), + REGULATOR_SUPPLY("power", "pwm-backlight"),
Quoted 4 lines
Without it
regulator_dev_lookup()won't match the device.Moreover, it requires a config option,
CONFIG_REGULATOR_FIXED_VOLTAGE=y. That's not a problem for my specific platform,
Okay. I'll submit a patch with that tweak of yours rolled in and Haojian can merge that via the PXA tree.
Quoted 3 lines
but I haven't seen *any* PXA platform
with it activated, which means all defconfigs have to be patched, which is unfortunate.
Unfortunate indeed!
Quoted 2 lines
As for my specific mioa701, your change with the tweak is perfectly fine and tested.
Great, I'll add your Tested-by.
Thanks,
Thierry
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20131220/4349c1b7/attachment-0001.sig>