Re: [PATCH V2] of: Fix of_empty_ranges_quirk()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Sep 7, 2019 at 5:15 PM <marek.vasut@xxxxxxxxx> wrote:
>
> From: Marek Vasut <marek.vasut+renesas@xxxxxxxxx>
>
> The of_empty_ranges_quirk() returns a mix of boolean and signed integer
> types, which cannot work well. Replace that with boolean only and fix
> usage logic in of_translate_one() -- the check should trigger when the
> ranges are NULL and the quirk is applicable on the hardware.

Just moving to boolean has seemed like weak justification for this
churn, but now that I've seen your work on PCI dma-ranges it makes a
bit more sense.

We do have a problem that unlike 'ranges', 'dma-ranges' being missing
probably needs to be treated as 1:1 translation. I can't really
picture a case where dma-ranges would be used with a non-translatable
address. Perhaps a module with optional DMA and the DMA is not hooked
up. That could be expressed with dma-ranges with a 0 size or a
different compatible. So your v1 patch was perhaps correct change in
behavior, but only for dma-ranges. (I've written one that works in
both cases).

Rob



[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux