[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <ZLjRR0xJZUWXXRf/@infradead.org>
Date: Wed, 19 Jul 2023 23:16:39 -0700
From: Christoph Hellwig <hch@...radead.org>
To: Sergei Shtepa <sergei.shtepa@...am.com>
Cc: Thomas Weißschuh <thomas@...ch.de>,
axboe@...nel.dk, hch@...radead.org, corbet@....net,
snitzer@...nel.org, viro@...iv.linux.org.uk, brauner@...nel.org,
dchinner@...hat.com, willy@...radead.org, dlemoal@...nel.org,
jack@...e.cz, ming.lei@...hat.com, linux-block@...r.kernel.org,
linux-doc@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-fsdevel@...r.kernel.org, Donald Buczek <buczek@...gen.mpg.de>
Subject: Re: [PATCH v5 04/11] blksnap: header file of the module interface
On Tue, Jul 18, 2023 at 11:53:54AM +0200, Sergei Shtepa wrote:
> > Seems a bit weird to have a signed error code that is always negative.
> > Couldn't this be an unsigned number or directly return the error from
> > the ioctl() itself?
>
> Yes, it's a good idea to pass the error code as an unsigned value.
> And this positive value can be passed in case of successful execution
> of ioctl(), but I would not like to put different error signs in one value.
Linux tends to use negative error values in basically all interfaces.
I think it will be less confusing to stick to that.
Powered by blists - more mailing lists