From mboxrd@z Thu Jan 1 00:00:00 1970 From: Simon Glass Date: Wed, 3 Feb 2021 14:42:22 -0700 Subject: [PATCH v2 1/1] sandbox: host bind must close file descriptor In-Reply-To: <20210202232156.323871-1-xypron.glpk@gmx.de> References: <20210202232156.323871-1-xypron.glpk@gmx.de> Message-ID: List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Tue, 2 Feb 2021 at 16:22, Heinrich Schuchardt wrote: > > Each invocation of the 'host bind' command with a file name argument opens > a file descriptor. The next invocation of the 'host bind' command destroys > the block device but the file descriptor remains open. The same holds true > for the 'unbind blk' command. > > Close the file descriptor when unbinding the host block device. > > Signed-off-by: Heinrich Schuchardt > --- > v2: > remove superfluous data checking > --- > drivers/block/sandbox.c | 13 +++++++++++++ > 1 file changed, 13 insertions(+) Reviewed-by: Simon Glass