linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Luis Chamberlain <mcgrof@kernel.org>
To: david@redhat.com, patches@lists.linux.dev,
	linux-modules@vger.kernel.org, linux-mm@kvack.org,
	linux-kernel@vger.kernel.org, pmladek@suse.com,
	petr.pavlu@suse.com, prarit@redhat.com,
	torvalds@linux-foundation.org, gregkh@linuxfoundation.org,
	rafael@kernel.org
Cc: christophe.leroy@csgroup.eu, tglx@linutronix.de,
	peterz@infradead.org, song@kernel.org, rppt@kernel.org,
	dave@stgolabs.net, willy@infradead.org, vbabka@suse.cz,
	mhocko@suse.com, dave.hansen@linux.intel.com,
	colin.i.king@gmail.com, jim.cromie@gmail.com,
	catalin.marinas@arm.com, jbaron@akamai.com,
	rick.p.edgecombe@intel.com, mcgrof@kernel.org
Subject: [PATCH v2 0/2] kmod: simplify with a semaphore
Date: Wed,  5 Apr 2023 13:35:03 -0700	[thread overview]
Message-ID: <20230405203505.1343562-1-mcgrof@kernel.org> (raw)

I split the semaphore simplification work out from my first patch series [0]
because as although the changes came out of that effort, in the end this set
of patches are slightly orthogonal to the goal behind that series and this
ended up being mostly a cleanup with mild bike shedding exercise.

As revealed from the first series, there is some tribal knowledge around
why some binary semaphores are not just mutexes, so we cannot just convert
them all to mutex. So I've extended Peter's patch with some of that tribal
knowledge.

Changes on this v2:

  o split this series up into its own
  o adopt Peter's patch and extend it with some documentation as to why
    some folks stick to binary semaphores over mutexes
  o modify kmod.c to use the preferred declaration

This goes boot tested.

[0] https://lkml.kernel.org/r/20230329053149.3976378-1-mcgrof@kernel.orgsemaphore

Luis Chamberlain (1):
  modules/kmod: replace implementation with a sempahore

Peter Zijlstra (1):
  Change DEFINE_SEMAPHORE() to take a number argument

 arch/mips/cavium-octeon/setup.c               |  2 +-
 arch/x86/kernel/cpu/intel.c                   |  2 +-
 drivers/firmware/efi/runtime-wrappers.c       |  2 +-
 drivers/firmware/efi/vars.c                   |  2 +-
 drivers/macintosh/adb.c                       |  2 +-
 .../net/ethernet/broadcom/bnx2x/bnx2x_main.c  |  2 +-
 drivers/platform/x86/intel/ifs/sysfs.c        |  2 +-
 drivers/scsi/esas2r/esas2r_ioctl.c            |  2 +-
 .../interface/vchiq_arm/vchiq_arm.c           |  2 +-
 include/linux/semaphore.h                     | 11 ++++++--
 kernel/module/kmod.c                          | 26 +++++--------------
 kernel/printk/printk.c                        |  2 +-
 net/rxrpc/call_object.c                       |  6 ++---
 13 files changed, 28 insertions(+), 35 deletions(-)

-- 
2.39.2



             reply	other threads:[~2023-04-05 20:35 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-05 20:35 Luis Chamberlain [this message]
2023-04-05 20:35 ` [PATCH v2 1/2] Change DEFINE_SEMAPHORE() to take a number argument Luis Chamberlain
2023-04-07 16:38   ` Davidlohr Bueso
2023-04-07 20:36   ` Matthew Wilcox
2023-04-07 20:52     ` Linus Torvalds
2023-04-12  4:05     ` Luis Chamberlain
2023-04-08  8:22   ` Sergey Senozhatsky
2023-04-05 20:35 ` [PATCH v2 2/2] modules/kmod: replace implementation with a sempahore Luis Chamberlain
2023-04-07 17:19   ` Davidlohr Bueso
2023-04-11  8:42   ` David Hildenbrand
2023-04-13  9:44   ` Miroslav Benes
2023-04-13 16:38     ` Luis Chamberlain

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230405203505.1343562-1-mcgrof@kernel.org \
    --to=mcgrof@kernel.org \
    --cc=catalin.marinas@arm.com \
    --cc=christophe.leroy@csgroup.eu \
    --cc=colin.i.king@gmail.com \
    --cc=dave.hansen@linux.intel.com \
    --cc=dave@stgolabs.net \
    --cc=david@redhat.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=jbaron@akamai.com \
    --cc=jim.cromie@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=linux-modules@vger.kernel.org \
    --cc=mhocko@suse.com \
    --cc=patches@lists.linux.dev \
    --cc=peterz@infradead.org \
    --cc=petr.pavlu@suse.com \
    --cc=pmladek@suse.com \
    --cc=prarit@redhat.com \
    --cc=rafael@kernel.org \
    --cc=rick.p.edgecombe@intel.com \
    --cc=rppt@kernel.org \
    --cc=song@kernel.org \
    --cc=tglx@linutronix.de \
    --cc=torvalds@linux-foundation.org \
    --cc=vbabka@suse.cz \
    --cc=willy@infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).