lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <e84f4146-b44f-b009-0dc4-876aa551f44f@huawei.com>
Date:   Mon, 27 Apr 2020 11:43:09 +0100
From:   John Garry <john.garry@...wei.com>
To:     Jiaxun Yang <jiaxun.yang@...goat.com>, <linux-mips@...r.kernel.org>
CC:     Thomas Bogendoerfer <tsbogend@...ha.franken.de>,
        Huacai Chen <chenhc@...ote.com>,
        Paul Burton <paulburton@...nel.org>,
        Thomas Gleixner <tglx@...utronix.de>,
        Stephen Kitt <steve@....org>,
        Nick Desaulniers <ndesaulniers@...gle.com>,
        Serge Semin <fancer.lancer@...il.com>,
        Anshuman Khandual <anshuman.khandual@....com>,
        Geert Uytterhoeven <geert@...ux-m68k.org>,
        Andrew Morton <akpm@...ux-foundation.org>,
        Daniel Silsby <dansilsby@...il.com>,
        Mike Rapoport <rppt@...ux.ibm.com>,
        Paul Cercueil <paul@...pouillou.net>,
        Mark Tomlinson <mark.tomlinson@...iedtelesis.co.nz>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Allison Randal <allison@...utok.net>,
        Tiezhu Yang <yangtiezhu@...ngson.cn>,
        Wei Xu <xuwei5@...ilicon.com>, <linux-kernel@...r.kernel.org>,
        Arnd Bergmann <arnd@...db.de>, Linuxarm <linuxarm@...wei.com>,
        Bjorn Helgaas <bhelgaas@...gle.com>,
        Rob Herring <robh@...nel.org>
Subject: Re: [PATCH 3/4] lib: logic_pio: Introduce MMIO_LOWER_RESERVED

On 26/04/2020 12:47, Jiaxun Yang wrote:
> That would allow platforms reserve some lower address in PIO MMIO range
> to deal with legacy drivers with hardcoded I/O ports that can't be
> managed by logic_pio.

Hi,

Is there some reason why the logic_pio code cannot be improved to handle 
these devices at these "fixed" addresses? Or do you have a plan to 
improve it? We already support fixed bus address devices in the INDIRECT 
IO region.

Carving out a region of IO space is less than ideal.

Thanks,
John

> 
> Signed-off-by: Jiaxun Yang <jiaxun.yang@...goat.com>
> ---
>   lib/logic_pio.c | 6 +++++-
>   1 file changed, 5 insertions(+), 1 deletion(-)
> 
> diff --git a/lib/logic_pio.c b/lib/logic_pio.c
> index f511a99bb389..57fff1cb7063 100644
> --- a/lib/logic_pio.c
> +++ b/lib/logic_pio.c
> @@ -20,6 +20,10 @@
>   static LIST_HEAD(io_range_list);
>   static DEFINE_MUTEX(io_range_mutex);
>   
> +#ifndef MMIO_LOWER_RESERVED
> +#define MMIO_LOWER_RESERVED	0
> +#endif
> +
>   /* Consider a kernel general helper for this */
>   #define in_range(b, first, len)        ((b) >= (first) && (b) < (first) + (len))
>   
> @@ -36,7 +40,7 @@ int logic_pio_register_range(struct logic_pio_hwaddr *new_range)
>   	struct logic_pio_hwaddr *range;
>   	resource_size_t start;
>   	resource_size_t end;
> -	resource_size_t mmio_end = 0;
> +	resource_size_t mmio_end = MMIO_LOWER_RESERVED;
>   	resource_size_t iio_sz = MMIO_UPPER_LIMIT;
>   	int ret = 0;
>   
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ