lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20230302144732.1903781-1-u.kleine-koenig@pengutronix.de>
Date:   Thu,  2 Mar 2023 15:47:03 +0100
From:   Uwe Kleine-König 
        <u.kleine-koenig@...gutronix.de>
To:     "Lee, Chun-Yi" <jlee@...e.com>,
        Hans de Goede <hdegoede@...hat.com>,
        Mark Gross <markgross@...nel.org>,
        Andrea Ho <Andrea.Ho@...antech.com.tw>,
        Naveen Krishna Chatradhi <naveenkrishna.chatradhi@....com>,
        Shyam Sundar S K <Shyam-sundar.S-k@....com>,
        Santosh Kumar Yadav <santoshkumar.yadav@...co.com>,
        Peter Korsgaard <peter.korsgaard@...co.com>,
        Cezary Jackiewicz <cezary.jackiewicz@...il.com>,
        Stuart Hayes <stuart.w.hayes@...il.com>,
        Pali Rohár <pali@...nel.org>,
        Eric Piel <eric.piel@...mplin-utc.net>,
        Barnabás Pőcze <pobrn@...tonmail.com>,
        Jorge Lopez <jorge.lopez2@...com>,
        Ike Panhc <ike.pan@...onical.com>,
        Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
        Wolfram Sang <wsa+renesas@...g-engineering.com>,
        Heikki Krogerus <heikki.krogerus@...ux.intel.com>,
        Maximilian Luz <luzmaximilian@...il.com>,
        Alex Hung <alexhung@...il.com>,
        Sebastian Andrzej Siewior <bigeasy@...utronix.de>,
        Thomas Gleixner <tglx@...utronix.de>,
        Shravan Sudhakar <s.shravan@...el.com>,
        Intel Corporation <linuxwwan@...el.com>,
        Daniel Scally <djrscally@...il.com>,
        Rajneesh Bhardwaj <irenic.rajneesh@...il.com>,
        "David E. Box" <david.e.box@...ux.intel.com>,
        AceLan Kao <acelan.kao@...onical.com>
Cc:     kernel@...gutronix.de,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        platform-driver-x86@...r.kernel.org, linux-kernel@...r.kernel.org,
        Carlos Bilbao <carlos.bilbao@....com>
Subject: [PATCH 00/29] platform/x86: Convert to platform remove callback returning void

Hello,

this patch series adapts the platform drivers below drivers/platform/x86
to use the .remove_new() callback. Compared to the traditional .remove()
callback .remove_new() returns no value. This is a good thing because
the driver core doesn't (and cannot) cope for errors during remove. The
only effect of a non-zero return value in .remove() is that the driver
core emits a warning. The device is removed anyhow and an early return
from .remove() usually yields a resource leak.

By changing the remove callback to return void driver authors cannot
reasonably assume any more that there is some kind of cleanup later.

All drivers touched here returned zero unconditionally in their remove
callback, so they could all be converted trivially to .remove_new().

Note that this series depends on commit 5c5a7680e67b ("platform: Provide
a remove callback that returns no value") that is already in Linus' tree
but not yet included in a tagged version.

Best regards
Uwe

Uwe Kleine-König (29):
  platform/x86: acer-wmi: Convert to platform remove callback returning void
  platform/x86: adv_swbutton: Convert to platform remove callback returning void
  platform/x86: amd: hsmp: Convert to platform remove callback returning void
  platform/x86: amd: pmc: Convert to platform remove callback returning void
  platform/x86: amd: pmf: core: Convert to platform remove callback returning void
  platform/x86: amilo-rfkill: Convert to platform remove callback returning void
  platform/x86: barco-p50-gpio: Convert to platform remove callback returning void
  platform/x86: compal-laptop: Convert to platform remove callback returning void
  platform/x86: dell: dcdbas: Convert to platform remove callback returning void
  platform/x86: dell: dell-smo8800: Convert to platform remove callback returning void
  platform/x86: hp: hp_accel: Convert to platform remove callback returning void
  platform/x86: hp: tc1100-wmi: Convert to platform remove callback returning void
  platform/x86: huawei-wmi: Convert to platform remove callback returning void
  platform/x86: ideapad-laptop: Convert to platform remove callback returning void
  platform/x86: intel: bxtwc_tmu: Convert to platform remove callback returning void
  platform/x86: intel: chtdc_ti_pwrbtn: Convert to platform remove callback returning void
  platform/x86: intel: chtwc_int33fe: Convert to platform remove callback returning void
  platform/x86: intel: hid: Convert to platform remove callback returning void
  platform/x86: intel: int0002_vgpio: Convert to platform remove callback returning void
  platform/x86: intel: int1092: intel_sar: Convert to platform remove callback returning void
  platform/x86: intel: int3472: discrete: Convert to platform remove callback returning void
  platform/x86: intel: mrfld_pwrbtn: Convert to platform remove callback returning void
  platform/x86: intel: pmc: core: Convert to platform remove callback returning void
  platform/x86: intel: telemetry: pltdrv: Convert to platform remove callback returning void
  platform/x86: intel: vbtn: Convert to platform remove callback returning void
  platform/x86: samsung-q10: Convert to platform remove callback returning void
  platform/x86: serial-multi-instantiate: Convert to platform remove callback returning void
  platform/x86: wmi: Convert to platform remove callback returning void
  platform/x86: xo1-rfkill: Convert to platform remove callback returning void

 drivers/platform/x86/acer-wmi.c                 |  5 ++---
 drivers/platform/x86/adv_swbutton.c             |  6 ++----
 drivers/platform/x86/amd/hsmp.c                 |  6 ++----
 drivers/platform/x86/amd/pmc.c                  |  5 ++---
 drivers/platform/x86/amd/pmf/core.c             |  5 ++---
 drivers/platform/x86/amilo-rfkill.c             |  5 ++---
 drivers/platform/x86/barco-p50-gpio.c           |  6 ++----
 drivers/platform/x86/compal-laptop.c            |  8 +++-----
 drivers/platform/x86/dell/dcdbas.c              |  6 ++----
 drivers/platform/x86/dell/dell-smo8800.c        |  5 ++---
 drivers/platform/x86/hp/hp_accel.c              |  5 ++---
 drivers/platform/x86/hp/tc1100-wmi.c            |  6 ++----
 drivers/platform/x86/huawei-wmi.c               |  6 ++----
 drivers/platform/x86/ideapad-laptop.c           |  6 ++----
 drivers/platform/x86/intel/bxtwc_tmu.c          |  5 ++---
 drivers/platform/x86/intel/chtdc_ti_pwrbtn.c    |  5 ++---
 drivers/platform/x86/intel/chtwc_int33fe.c      |  6 ++----
 drivers/platform/x86/intel/hid.c                | 10 ++--------
 drivers/platform/x86/intel/int0002_vgpio.c      |  5 ++---
 drivers/platform/x86/intel/int1092/intel_sar.c  |  5 ++---
 drivers/platform/x86/intel/int3472/discrete.c   |  6 ++----
 drivers/platform/x86/intel/mrfld_pwrbtn.c       |  5 ++---
 drivers/platform/x86/intel/pmc/core.c           |  5 ++---
 drivers/platform/x86/intel/telemetry/pltdrv.c   |  5 ++---
 drivers/platform/x86/intel/vbtn.c               | 10 ++--------
 drivers/platform/x86/samsung-q10.c              |  6 ++----
 drivers/platform/x86/serial-multi-instantiate.c |  6 ++----
 drivers/platform/x86/wmi.c                      |  6 ++----
 drivers/platform/x86/xo1-rfkill.c               |  5 ++---
 29 files changed, 59 insertions(+), 111 deletions(-)

base-commit: ee3f96b164688dae21e2466a57f2e806b64e8a37
-- 
2.39.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ