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: <CAK8P3a3ojRSpC3GVU6P05GEtj7AHxrYD_ZrAZaa68KT14H9Hew@mail.gmail.com>
Date:   Fri, 24 Mar 2017 22:23:48 +0100
From:   Arnd Bergmann <arnd@...db.de>
To:     Tobias Regnery <tobias.regnery@...il.com>
Cc:     Rob Herring <robh+dt@...nel.org>, devicetree@...r.kernel.org,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        Simon Horman <horms@...ge.net.au>
Subject: Re: [PATCH] of: add stub for of_n_addr_cells

On Fri, Mar 24, 2017 at 11:39 AM, Tobias Regnery
<tobias.regnery@...il.com> wrote:
> With CONFIG_OF=n and CONFIG_COMPILE_TEST=y the rcar pci-e driver fails to
> build on arm:
>
> drivers/pci/host/pcie-rcar.c: In function 'pci_dma_range_parser_init':
> drivers/pci/host/pcie-rcar.c:1035:16: error: implicit declaration of function 'of_n_addr_cells' [-Werror=implicit-function-declaration]
>   parser->pna = of_n_addr_cells(node);
>                 ^~~~~~~~~~~~~~~
>
> Fix this by adding an inline stub for of_n_addr_cells
>
> Signed-off-by: Tobias Regnery <tobias.regnery@...il.com>
> ---
> This is against next-20140324
>
>  include/linux/of.h | 5 +++++
>  1 file changed, 5 insertions(+)
>
> diff --git a/include/linux/of.h b/include/linux/of.h
> index 21e6323de0f3..9978c918222e 100644
> --- a/include/linux/of.h
> +++ b/include/linux/of.h
> @@ -710,6 +710,11 @@ static inline struct device_node *of_get_cpu_node(int cpu,
>         return NULL;
>  }
>
> +static inline int of_n_addr_cells(struct device_node *np)
> +{
> +       return 0;
> +}
> +

This looks good, but we should also do the same thing for of_n_size_cells().

I think I sent something like this a few years ago, but never resubmitted it
when it was ignored at first.

        Arnd

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ