[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHk-=wh=_T=A53+o4zLNbKio43LGqVDb0KCbWPDvAg54bRDmWw@mail.gmail.com>
Date: Thu, 22 Nov 2018 08:50:47 -0800
From: Linus Torvalds <torvalds@...ux-foundation.org>
To: Christoph Hellwig <hch@....de>
Cc: iommu@...ts.linux-foundation.org, jdmason@...zu.us,
joro@...tes.org, David Woodhouse <dwmw2@...radead.org>,
m.szyprowski@...sung.com, robin.murphy@....com,
"the arch/x86 maintainers" <x86@...nel.org>,
linux-alpha@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
linux-ia64@...r.kernel.org, linux-parisc@...r.kernel.org,
xen-devel@...ts.xenproject.org, linux-arch@...r.kernel.org,
Linux List Kernel Mailing <linux-kernel@...r.kernel.org>
Subject: Re: remove the ->mapping_error method from dma_map_ops V2
On Thu, Nov 22, 2018 at 6:03 AM Christoph Hellwig <hch@....de> wrote:
>
> The 0 return doesn't work for direct mappings that have ram at address
> zero and a lot of IOMMUs that start allocating bus space from address
> zero, so we can't consolidate on that, but I think we can move everyone
> to all-Fs, which the patch here does.
Hmm. Maybe not limit it to just all ones, but actually use the
(standard, for the kernel) IS_ERR_VALUE()?
That basically reserves the last 4095 values in an unsigned long for
error values.
Then those functions could actually return *what* error they
encountered, using just plain
return -ENOMEM;
or whatever?
Linus
Powered by blists - more mailing lists