#
…

2021-11-26

03:07method_ has quit [Ping timeout: 480 seconds]
03:15phiologe has quit [Ping timeout: 480 seconds]
03:56Method has joined #asahi-dev
03:57kov has quit [Quit: Coyote finally caught me]
04:57marcanjevinskie[m]: yes it is, ha
04:59marcanjevinskie[m]: fixed, thanks :)
05:53the_lanetly_052__ has joined #asahi-dev
06:08marcanrobher_: to revisit the "tunables" issue, what are your thoughts on blobs in the DT? Apple puts a pile of register pokes in the DT to configure the USB3/Thunderbolt/DP PHYs... and in this case AIUI they have to be applied at runtime depending on what's connected
06:08marcanI checked and they do indeed differ between different devices using the same SoC, though only slightly (not sure if they differ between different units of the same device)
06:08marcanso we can't just throw it into the driver :/
06:09marcanI think this has come up a few times before in vendor trees, but I don't know if any mainlined driver does this kind of thing?
06:10marcanlol, soc/fsl/cpm_qe/qe.txt apparently puts an entire *firmware* blob in the devicetree? :D
06:15marcanI see there's some precedent in stuff like qcom,ath10k-pre-calibration-data, but those are opaque blobs
06:15marcanI don't know if there's anything that's a list of registers to write and values/masks
06:16marcan(which is what we have)
06:36the_lanetly_052__ has quit [Ping timeout: 480 seconds]
07:23jannauis the difference between devices in the written values or are there differences in the registers or the order of writes?
07:24jannauif only values differ it can be easily transformed into a blob. The only disadvantage is that forward compatibility might not be possible
07:25jannaumarcan: don't we need to wait for Rob's ack on the iMac addition in the bindings change as well
07:26marcanyes, it's along similar lines though
07:27marcanjannau: usually the written values, but sometimes there's an extra reg or a whole tunable is missing/empty
07:27marcanI think if we're doing this it's not worth trying to hardcode the offsets
07:29marcanin fact, given what Apple did with t6000 in the memory controller, if this kind of thing is acceptable I'm tempted to use it for the mcc OPP table too, since t8103 needs two pokes and t6000 only one (to a different place) for the performance switching, but they're otherwise identical in high-level construction (number of channels differs but that was a variable already)
07:29marcanI figure if we're putting magic reg values in the DT at all, we might as well put the reg addresses too and make it forward-compatible
07:29marcanthough right now apple uses the same values for everything in the MCC case, so alternatively this could all be hardcoded in the driver and driven by the SoC compatible
07:36the_lanetly_052__ has joined #asahi-dev
09:18aleasto has joined #asahi-dev
09:43kov has joined #asahi-dev
10:48akemin_dayo has quit [Ping timeout: 480 seconds]
11:10kettenisthe MCC driver isn't really essential is it?
11:12kettenisI mean, things will still work if for some future SoC the driver isn't there
11:32marcanyes, it isn't, as long as cpufreq doesn't fail poorly without it
11:33marcanthough I think other parts of MCC are more stable between SoCs, e.g. we should implement error control
11:46kettenisso then you'd need a "generic" compatible and you'd only apply the values if a more specific compatible matches as well
11:46kettenisif you choose to put the values in the driver that is
11:48kettenisbut maybe the actual values depend on the RAM modules integrated in the SoC?
11:49kettenisand Apple will maybe source different RAM modules at some point that need different parameters?
11:49marcannah, I don't think so. they're power management timers.
11:50marcanI don't think it changes any characteristics of the interface, it just changes how eagerly it goes into lower power modes (to reduce cache miss latency when the CPUs are busy)
11:50marcanI tried random values, zero, etc, and nothing broke (in fact I got better performance with zero, which presumably turns off all the PM stuff altogether)
12:02poviki am thinking about how i should express the MCA stuff in DT
12:02povikseems to me there should be one parent node for the MCA block as a whole
12:02povikand then child nodes for particular subdivisions, let's call them clusters
12:03poviknow the clusters need to have a cluster index within the MCA as a whole
12:03povikand also clusters have associated mmio ranges, which cannot be systematically derived from some large range for the whole MCA
12:04poviki am thinking the cluster index should be in the reg= of the child nodes
12:04povika then the mmio ranges for the clusters should be listed in the parent node
12:05kettenisthat sounds wrong
12:05povikanother option is having the mmio ranges in reg= of the cluster nodes, and then an extra property for the cluster index
12:06ketteniswhat do you need the cluster index for?
12:06povikit is important for configuration in some registers
12:08kettenisthen I'd suggest using a property for that
12:09kettenis"apple,cluster"
12:10povikcluster-idx perhaps?
12:12kettenissure; but maybe check the existing bindings to see if there is an established pattern for such things
12:13kettenisyou can add a "syscon" compatible to the MCA block node to make it provide a regmap
12:13kettenisand then use the "reg" property in the child nodes to provide offsets within the block of registers
12:18povikhm, haven't seen "syscon" yet, will look at that
12:19marcansee how pmgr does it
12:20marcanthough there's two ways, if you add a simple-mfd compatible it will probe the child nodes for you; if you don't it won't and the parent will be in charge of requesting that (which makes more sense if you have a common driver)
12:20marcanalso look at other ALSA/ASoC stuff because there's a good chance some other SoC does it similarly
12:21kettenisthere are two schemes for specifying how the various audio components are related
12:22kettenisand it isn't clear to me what the preferred way of doing that is
12:23kettenis"simple-audio" and "audio-graph"
12:27not_a_weeaboo[m] has joined #asahi-dev
12:30akemin_dayo has joined #asahi-dev
15:09akemin_dayo has quit [Ping timeout: 480 seconds]
16:11akemin_dayo has joined #asahi-dev
16:16the_lanetly_052___ has joined #asahi-dev
16:22the_lanetly_052__ has quit [Ping timeout: 480 seconds]
16:46indra has joined #asahi-dev
16:50leah has quit [Quit: WeeChat 3.3]
16:55indra has quit []
17:31slicey has joined #asahi-dev
17:38Gaspare has joined #asahi-dev
17:55yuyichao has quit [Ping timeout: 480 seconds]
18:16yuyichao has joined #asahi-dev
18:21littledust3403[m] has joined #asahi-dev
20:02akemin_dayo has quit [Ping timeout: 480 seconds]
20:03akemin_dayo has joined #asahi-dev
20:04sventhe rtkit protocol seems to have at least the following power states: 0, 1, 2, maybe 3, 0x10, 0x20 and i think you can set an additional flag (0x200) for some of them which does $something while it's ignored for others
20:04sven0 it power off, 0x20 is power on (and so is 0x220 which seems to be the same). 0x10 is some kind of hibernation or sleep mode. no idea yet about 1 or 2 (or maybe 3; need to double check tomorrow) or what that flag means
20:10aleasto has quit [Remote host closed the connection]
21:21Dcow has quit [Read error: Connection reset by peer]
21:21Dcow_ has joined #asahi-dev
21:33Gaspare has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
21:36Gaspare has joined #asahi-dev
21:59slicey has quit [Quit: zzz]
22:12Gaspare has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
22:57slicey has joined #asahi-dev
22:57Gaspare has joined #asahi-dev
23:28yuyichao has quit [Ping timeout: 480 seconds]
23:51Gaspare has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
23:51Gaspare has joined #asahi-dev
23:51X-Scale` has joined #asahi-dev
23:57X-Scale has quit [Ping timeout: 480 seconds]
23:59X-Scale has joined #asahi-dev
…