ChanServ changed the topic of #armlinux to: ARM kernel talk [Upstream kernel, find your vendor forums for questions about their kernels] | https://libera.irclog.whitequark.org/armlinux
tfiga has quit [Ping timeout: 258 seconds]
jhswartz has quit [Quit: leaving]
tfiga has joined #armlinux
gpiccoli has quit [Quit: Quit...]
gpiccoli has joined #armlinux
apritzel has quit [Ping timeout: 265 seconds]
wwilly has quit [Ping timeout: 268 seconds]
prabhakarlad has quit [Quit: Client closed]
CrashTestDummy2 has quit [Quit: Leaving]
CrashTestDummy has joined #armlinux
Bobathan has joined #armlinux
paulg has quit [Ping timeout: 272 seconds]
wwilly has joined #armlinux
wwilly has quit [Ping timeout: 265 seconds]
apritzel has joined #armlinux
frieder has joined #armlinux
apritzel has quit [Ping timeout: 268 seconds]
CrashTestDummy2 has joined #armlinux
CrashTestDummy has quit [Ping timeout: 252 seconds]
prabhakarlad has joined #armlinux
alpernebbi has joined #armlinux
sszy has joined #armlinux
frieder has quit [Ping timeout: 268 seconds]
audgirka has joined #armlinux
wwilly has joined #armlinux
wwilly_ has joined #armlinux
wwilly has quit [Ping timeout: 252 seconds]
CrashTestDummy3 has joined #armlinux
CrashTestDummy2 has quit [Ping timeout: 252 seconds]
frieder has joined #armlinux
Pali has joined #armlinux
wwilly_ has quit [Quit: Leaving]
wwilly has joined #armlinux
psydroid has quit [Quit: Bridge terminating on SIGTERM]
shoragan[m] has quit [Quit: Bridge terminating on SIGTERM]
mvaittin has quit [Quit: Bridge terminating on SIGTERM]
sha has quit [Quit: Bridge terminating on SIGTERM]
jlinton has quit [Quit: Client closed]
Pali has quit [Ping timeout: 252 seconds]
audgirka has quit [Quit: Leaving]
audgirka has joined #armlinux
Crassus has joined #armlinux
audgirka has quit [Remote host closed the connection]
audgirka has joined #armlinux
matthias_bgg has joined #armlinux
apritzel has joined #armlinux
nsaenz has quit [Remote host closed the connection]
<mort>
there's an enable-gpios and a power-supply property too, but those are both commented out
nsaenz has quit [Remote host closed the connection]
paulg has joined #armlinux
nsaenz has joined #armlinux
<javierm>
mort: Documentation/devicetree/bindings/leds/backlight/pwm-backlight.yaml says that power-supply is also a required property
<javierm>
mort: the driver is using devm_regulator_get(), so it won't probe if the regulator is missing in your backlight node
<mort>
hmm, I understood from someone else on here (or was it in #oe?) that it shouldn't be an issue. I might've misunderstood something though
<mort>
upgraded to 5.7 and backlight is deferred
<javierm>
mort: I always get confused by this API... I think devm_regulator_get_optional() is when you want the core to fill a dummy regulator
<javierm>
I'll need to read the code again to remember
<mort>
well, when loading pwm_bl it prints "[ 315.315579] pwm-backlight backlight: supply power not found, using dummy regulator" which indicates that it's using dummy regulator
<mort>
but it certainly calls devm_regulator_get, not devm_regulator_get_optional
<mort>
weird, I'm unable to enable dynamic debug from pwm_bl.c
<mort>
I think this is a kernel with it enabled
<broonie>
clocks and regulators are the opposite way around WRT optional supplies is what's confusing. Pretty sure regulator was there first :)
<mort>
dynamic debugging is enabled, writing 'file * +p' to dynamic_debug/control spams the dmesg log, but writing 'file pwm_bl.c +p' didn't make the dev_dbg lines in pwm_bl.c appear in dmesg
<javierm>
broonie: yeah, reading the core I remembered but I get those conflated all the time :)
<javierm>
mort: can you share the node for pm8916_pwm ?
<broonie>
javierm: I think lots of people do due to the inconsistency, it's kind of sad.
<javierm>
mort: ah. That file content is hard to parse but it's basically telling you that backlight device node was deferred due pm8916
<javierm>
which matches what we thought
<javierm>
mort: I guess your 4.14 or whatever kernel version that worked had this out-of-tree driver and that was dropped when rebased to 5.7
<mort>
no, I thought that too, but I checked out the release/kernel-17.06.1 branch (linux 4.9.39) and that has no source code which contains the string pm8916-pwm either
<javierm>
mort: and the DTS is the same?
<javierm>
that's surprising
<mort>
well, we include dtsi files which have changed, I can try to figure out if anything pm8916-related has changed in those
<mort>
but we *definitely* had `compatible = "qcom,pm8916-pwm";` in the pwm@bc00 node when it worked, and backlight was referring to pwm-backlight then too
<mort>
"pwms = <&pm8916_pwm 0 100000>;" is unchanged too
<mort>
so the pm8916 is using the driver compatible with qcom,pm8916 (that's in mfd/qcom-spmi-pmic.c). I have no idea what ends up drivingn the pm8916-pwm though. Could the parent node's driver (that's the qcom-spmi-pmic one) take somehow take care of all its child nodes, regardless of the compatible string?
<mort>
holy fucking shit I'm stupid
<javierm>
mort: that's the parent MFD, you want to check pm8916_pwm: pwm@bc00
<mort>
pm8916-pwm is supported through a kernel patch we've been applying but which I removed when trying to upgrade the kernel
<javierm>
mort: ah, so the theory was correct then :)
<mort>
yeah, just not "out-of-tree" from the soc vendor, "out-of-tree" from a .patch file in a bitbake recipe
<javierm>
mort: right, I meant "not in mainline"
<mort>
you were correct, I just didn't consider all the ways for a driver to be out of tree :p
<javierm>
:)
<mort>
honestly, I think there's a valuable lesson here: sometimes, the question isn't, "why isn't this working anymore", but "why was this working before" and I've been way too focused on the former through this whole debugging endeavor
<javierm>
mort: yeah. There are too many moving pieces that make it hard to figure out
<mort>
honestly, who would've expected an out-of-tree kernel patch applied as a .patch file in a bitbake recipe to support using the pm8916 chip as a pwm controller
<mort>
for stupid reasons, I can't make a new build right now, but I'll test tomorrow. I'm betting I just have to take that patch and make sure it's applied and then everything will work
<mort>
anyways, thanks a ton for your help javierm
<javierm>
mort: yeah, probably will work once the pwm device driver is there and probes correctly