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: <CAL_JsqJDpEHBcWeCqxSiUjpyBs0gEJKVyyR70xJO56x-pYQHMw@mail.gmail.com>
Date: Wed, 27 Aug 2025 11:16:20 -0500
From: Rob Herring <robh@...nel.org>
To: James Morse <james.morse@....com>
Cc: linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org, 
	linux-acpi@...r.kernel.org, devicetree@...r.kernel.org, 
	shameerali.kolothum.thodi@...wei.com, 
	D Scott Phillips OS <scott@...amperecomputing.com>, carl@...amperecomputing.com, 
	lcherian@...vell.com, bobo.shaobowang@...wei.com, tan.shaopeng@...itsu.com, 
	baolin.wang@...ux.alibaba.com, Jamie Iles <quic_jiles@...cinc.com>, 
	Xin Hao <xhao@...ux.alibaba.com>, peternewman@...gle.com, dfustini@...libre.com, 
	amitsinght@...vell.com, David Hildenbrand <david@...hat.com>, 
	Rex Nie <rex.nie@...uarmicro.com>, Dave Martin <dave.martin@....com>, 
	Koba Ko <kobak@...dia.com>, Shanker Donthineni <sdonthineni@...dia.com>, fenghuay@...dia.com, 
	baisheng.gao@...soc.com, Jonathan Cameron <jonathan.cameron@...wei.com>, 
	Rohit Mathew <rohit.mathew@....com>, Rafael Wysocki <rafael@...nel.org>, Len Brown <lenb@...nel.org>, 
	Lorenzo Pieralisi <lpieralisi@...nel.org>, Hanjun Guo <guohanjun@...wei.com>, 
	Sudeep Holla <sudeep.holla@....com>, Krzysztof Kozlowski <krzk+dt@...nel.org>, 
	Conor Dooley <conor+dt@...nel.org>, Catalin Marinas <catalin.marinas@....com>, 
	Will Deacon <will@...nel.org>, Greg Kroah-Hartman <gregkh@...uxfoundation.org>, 
	Danilo Krummrich <dakr@...nel.org>
Subject: Re: [PATCH 10/33] arm_mpam: Add probe/remove for mpam msc driver and
 kbuild boiler plate

On Wed, Aug 27, 2025 at 10:39 AM Rob Herring <robh@...nel.org> wrote:
>
> On Fri, Aug 22, 2025 at 10:32 AM James Morse <james.morse@....com> wrote:
> >
> > Probing MPAM is convoluted. MSCs that are integrated with a CPU may
> > only be accessible from those CPUs, and they may not be online.
> > Touching the hardware early is pointless as MPAM can't be used until
> > the system-wide common values for num_partid and num_pmg have been
> > discovered.

[...]

> > +static int mpam_dt_parse_resources(struct mpam_msc *msc, void *ignored)
> > +{
> > +       int err, num_ris = 0;
> > +       const u32 *ris_idx_p;
> > +       struct device_node *iter, *np;
> > +
> > +       np = msc->pdev->dev.of_node;
> > +       for_each_child_of_node(np, iter) {
>
> Use for_each_available_child_of_node_scoped()
>
> > +               ris_idx_p = of_get_property(iter, "reg", NULL);
>
> This is broken on big endian and new users of of_get_property() are
> discouraged. Use of_property_read_reg().

Err, this is broken on little endian as the DT is big endian.

So this was obviously not tested as I'm confident you didn't test on BE.

Rob

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ