On Tue, Jan 26, 2021 at 5:57 PM Mika Westerberg <mika.westerberg@xxxxxxxxxxxxxxx> wrote: > > From: Mario Limonciello <mario.limonciello@xxxxxxxx> > > The platform _OSC can change the hardware state when query bit is not > set. According to ACPI spec it is recommended that the OS runs _OSC with > query bit set until the platform does not mask any of the capabilities. > Then it should run it with query bit clear in order to actually commit > the changes. At the moment Linux only runs the _OSC with query bit set > and this is going to cause problems with the USB4 CM (Connection > Manager) switch that is going to commit the switch only when the OS > requests control over the feature. > > For this reason modify the _OSC support so that we first execute it with > query bit set, then use the returned valu as base of the features we Totally out of my depth here, but just noticed the typo (valu => value). > want to control and run the _OSC again with query bit clear. > > Also rename the function to better match what it does. > > Cc: Rafael J. Wysocki <rafael.j.wysocki@xxxxxxxxx> > Signed-off-by: Mario Limonciello <mario.limonciello@xxxxxxxx> > Signed-off-by: Mika Westerberg <mika.westerberg@xxxxxxxxxxxxxxx> > ---