[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAKhg4tLchH_+sR7VXq=hR7tHU_NRsrsxk6PVTfYx1-B5pA0W+w@mail.gmail.com>
Date: Thu, 6 Jul 2017 08:18:02 +0800
From: Liang Chen <liangchen.linux@...il.com>
To: Christoph Hellwig <hch@...radead.org>
Cc: linux-bcache@...r.kernel.org, linux-kernel@...r.kernel.org,
colyli@...e.de, bcache@...ux.ewheeler.net
Subject: Re: [PATCH] bcache: avoid a dangerous addressing in closure_queue
I had the same feeling, and was reluctant to do so. The reason for making this
change was that current code implicitly converts work_func_t to closure_fn, and
it also depends on the offset and size of a few struct not being changed. So the
patch was introduced essentially to solve that, and keep the impact small
meanwhile.
But as you pointed out, explicit casting is still bad too (was hoping it can be
considered less bad at this situation). I will think of a better idea
to handle this
issue unless people agree that the current behaviour is safe.
Powered by blists - more mailing lists