Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1176695

Re: [PATCH 3/6] Fix unsafe sas_device_list usage

From Christoph Hellwig <hch@infradead.org>
Newsgroups linux.kernel
Subject Re: [PATCH 3/6] Fix unsafe sas_device_list usage
Date 2015-07-03 18:10 +0200
Message-ID <pIbHj-2fv-11@gated-at.bofh.it> (permalink)
References <pqeNj-4f4-3@gated-at.bofh.it> <pziRH-34C-3@gated-at.bofh.it> <pziRH-34C-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Mon, Jun 08, 2015 at 08:50:53PM -0700, Calvin Owens wrote:
> We cannot iterate over the list without holding a lock for the entire
> duration, or we risk corrupting random memory if items are added or
> deleted as we iterate.
> 
> This refactors code such that it always holds the lock when iterating
> on or accessing the sas_device_list.

This looks sensible but should probably be folded into the previous
patch.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | Next | Find similar | Unroll thread


Thread

Re: [PATCH 3/6] Fix unsafe sas_device_list usage Christoph Hellwig <hch@infradead.org> - 2015-07-03 18:10 +0200

csiph-web