From: Lee Duncan <lduncan@suse.com>
To: linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: Hannes Reinecke <hare@suse.com>,
Johannes Thumshirn <jthumshirn@suse.de>,
Christoph Hellwig <hch@infradead.org>,
Lee Duncan <lduncan@suse.com>,
Kai.Makisara@kolumbus.fi, Mike Snitzer <snitzer@redhat.com>,
Doug Ledford <dledford@redhat.com>,
Ulf Hansson <ulf.hansson@linaro.org>,
Gerd Hoffmann <kraxel@redhat.com>,
Samuel Ortiz <sameo@linux.intel.com>,
Alex Dubov <oakad@yahoo.com>,
Joshua Morris <josh.h.morris@us.ibm.com>,
Matthew Wilcox <willy@linux.intel.com>
Subject: [PATCH 00/17] Create and use ida and idr helper routines
Date: Tue, 15 Sep 2015 09:46:00 -0700 [thread overview]
Message-ID: <cover.1442263512.git.lduncan@suse.com> (raw)
The idr index management library supplies two sets of routines
for managing monotonically increasing index numbers. The "ida"
set of routines manage allocating and freeing simple index
numbers. The "idr" set of routines add the ability to save
an arbitrary pointer with each index.
Both sets of routines are used throughout the kernel, and it
was noted that many of them use the same or similar calling
sequences, making a helper function a useful addition.
This set of patches adds some helper functions, defined
as inline in <linux/idr.h>. In addition, any of the clients
of these idr library functions that could benefit from
using these helper functions where modified to use them.
In addition to cleaning up the code in the clients of these
functions, the SCSI hosts module, which used to use a simple
atomic integer for index management is converted to using
the idr set of routines to manage its index values as
well as to simplify and speed up host number to instance
lookups.
I have functionally tested the SCSI host indexing change,
and I have compile tested all of the other changes. The
maintainers of each driver are cc-ed on the patch series,
where available.
Note: I did not mark this patch series as "v2" since
the scope of the patch set has grown considerably
since my first submissions.
Summary: There is one patch that adds helper functions, 11
patches that use the new "idr" helper functions, and 5 that
use the new "ida" helper functions.
Lee Duncan (17):
1. Add ida and idr helper routines.
2. Update scsi hosts to use idr for host number mgmt
3. Update the st driver to use idr helper functions.
4. Update the ch driver to use idr helper functions.
5. Update the md driver to use idr helper functions.
6. Update the infiniband uverbs driver to use idr helper functions.
7. Update the memstick driver to use idr helper functions.
8. Update the mmc driver to use idr helper functions.
9. Update the virtgpu driver to use idr helper functions.
10. Update the DCA DMA driver to use idr helper functions.
11. Update the rtsx multifunction driver to use idr helper functions.
12. Update the TI Flash Media driver to use idr helper functions.
13. Update the SCSI disk driver to use ida helper functions.
14. Update the rsxx flash adapter driver to use ida helper functions.
15. Update the NVMe SSD driver to use ida helper functions.
16. Update the Micron PCIe SSD driver to use ida helper functions.
17. Update the ARM soc base driver to use ida helper functions.
drivers/base/soc.c | 17 ++----
drivers/block/mtip32xx/mtip32xx.c | 22 ++------
drivers/block/nvme-core.c | 14 +----
drivers/block/rsxx/core.c | 16 +-----
drivers/dca/dca-sysfs.c | 19 ++-----
drivers/gpu/drm/virtio/virtgpu_vq.c | 15 ++----
drivers/infiniband/core/uverbs_cmd.c | 12 +----
drivers/md/dm.c | 22 ++------
drivers/memstick/core/memstick.c | 19 ++-----
drivers/mfd/rtsx_pcr.c | 13 ++---
drivers/misc/tifm_core.c | 17 ++----
drivers/mmc/core/host.c | 14 ++---
drivers/scsi/ch.c | 14 ++---
drivers/scsi/hosts.c | 59 ++++++++++----------
drivers/scsi/sd.c | 20 ++-----
drivers/scsi/st.c | 15 ++----
include/linux/idr.h | 102 +++++++++++++++++++++++++++++++++++
17 files changed, 182 insertions(+), 228 deletions(-)
--
2.1.4
next reply other threads:[~2015-09-15 16:46 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-15 16:46 Lee Duncan [this message]
2015-09-15 16:46 ` [PATCH 01/17] Add ida and idr helper routines Lee Duncan
2015-09-15 18:20 ` James Bottomley
2015-09-15 18:27 ` Tejun Heo
2015-09-15 18:38 ` James Bottomley
2015-09-15 18:41 ` Tejun Heo
2015-09-18 15:42 ` Lee Duncan
2015-09-18 15:49 ` Tejun Heo
2015-09-15 16:46 ` [PATCH 02/17] Update scsi hosts to use idr for host number mgmt Lee Duncan
2015-09-15 16:46 ` [PATCH 03/17] Update the st driver to use idr helper functions Lee Duncan
2015-09-15 16:46 ` [PATCH 04/17] Update the ch " Lee Duncan
2015-09-15 16:46 ` [PATCH 05/17] Update the md " Lee Duncan
2015-09-15 18:05 ` Mike Snitzer
2015-09-17 20:51 ` Lee Duncan
2015-09-15 16:46 ` [PATCH 06/17] Update the infiniband uverbs " Lee Duncan
2015-09-15 16:46 ` [PATCH 07/17] Update the memstick " Lee Duncan
2015-09-15 16:46 ` [PATCH 08/17] Update the mmc " Lee Duncan
2015-09-16 6:48 ` Ulf Hansson
2015-09-15 16:46 ` [PATCH 09/17] Update the virtgpu " Lee Duncan
2015-09-15 16:46 ` [PATCH 10/17] Update the DCA DMA " Lee Duncan
2015-09-15 16:46 ` [PATCH 11/17] Update the rtsx multifunction " Lee Duncan
2015-09-15 16:46 ` [PATCH 12/17] Update the TI Flash Media " Lee Duncan
2015-09-15 16:46 ` [PATCH 13/17] Update the SCSI disk driver to use ida " Lee Duncan
2015-09-15 16:46 ` [PATCH 14/17] Update the rsxx flash adapter " Lee Duncan
2015-09-15 16:46 ` [PATCH 15/17] Update the NVMe SSD " Lee Duncan
2015-09-15 16:46 ` [PATCH 16/17] Update the Micron PCIe " Lee Duncan
2015-09-15 16:46 ` [PATCH 17/17] Update the ARM soc base " Lee Duncan
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=cover.1442263512.git.lduncan@suse.com \
--to=lduncan@suse.com \
--cc=Kai.Makisara@kolumbus.fi \
--cc=dledford@redhat.com \
--cc=hare@suse.com \
--cc=hch@infradead.org \
--cc=josh.h.morris@us.ibm.com \
--cc=jthumshirn@suse.de \
--cc=kraxel@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=oakad@yahoo.com \
--cc=sameo@linux.intel.com \
--cc=snitzer@redhat.com \
--cc=ulf.hansson@linaro.org \
--cc=willy@linux.intel.com \
/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).