1. 21 Dec, 2021 4 commits
  2. 15 Dec, 2021 1 commit
  3. 13 Dec, 2021 9 commits
  4. 07 Dec, 2021 4 commits
  5. 06 Dec, 2021 4 commits
  6. 02 Dec, 2021 6 commits
  7. 25 Nov, 2021 11 commits
  8. 22 Nov, 2021 1 commit
    • Hans de Goede's avatar
      platform/x86: thinkpad_acpi: Accept ibm_init_struct.init() returning -ENODEV · c15f8685
      Hans de Goede authored
      Commit 79f960e2 ("platform/x86: thinkpad_acpi: Convert platform driver
      to use dev_groups") accidentally modified tpacpi_kbdlang_init() causing it
      to return -ENODEV instead of 0 on machines without kbdlang support
      (which are most of them).
      
      ibm_init() sees this -ENODEV as an error causing the entire module to not
      load, not good.
      
      Note that technically tpacpi_kbdlang_init() was already buggy before, it
      should have returned 1 instead of 0 if the feature is not present.
      
      Rather then fixing tpacpi_kbdlang_init() though, IMHO it is bettter to
      just make ibm_init() treat -ENODEV as 1 to fix the issue; and then in
      a followup commit also change all the existing "return 1"s from
      ibm_init_struct.init() callbacks to "return -ENODEV" as -ENODEV clearly
      states what it going on where as a magic return of "1" requires a deep
      dive into the code to figure out what is going on.
      
      This will also allow removing some extra ifs to translate -ENODEV to
      return 1 in a couple of init() callbacks.
      
      Fixes: 79f960e2 ("platform/x86: thinkpad_acpi: Convert platform driver to use dev_groups")
      Cc: Len Baker <len.baker@gmx.com>
      Reviewed-by: default avatarAndy Shevchenko <andy.shevchenko@gmail.com>
      Signed-off-by: default avatarHans de Goede <hdegoede@redhat.com>
      Link: https://lore.kernel.org/r/20211121191129.256713-2-hdegoede@redhat.com
      c15f8685