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: <20231207111055.GF50400@kernel.org>
Date:   Thu, 7 Dec 2023 11:10:55 +0000
From:   Simon Horman <horms@...nel.org>
To:     Min Li <min.li.xe@...esas.com>
Cc:     Paolo Abeni <pabeni@...hat.com>, Min Li <lnimi@...mail.com>,
        "richardcochran@...il.com" <richardcochran@...il.com>,
        "lee@...nel.org" <lee@...nel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>
Subject: Re: [PATCH net-next v6 1/6] ptp: clockmatrix: support 32-bit address
 space

On Wed, Dec 06, 2023 at 04:29:09PM +0000, Min Li wrote:
> > >
> > > Hi Min Li,
> > >
> > > My understanding of Paolo's review of v5 was that it would be cleaner to:
> > >
> > > 1. Leave the type of the module parameter as u16 2. Update the type of
> > > the regaddr parameter to u32
> > 
> > [almost over the air conflict here ;) ]
> > 
> > I think the module parameter as u32 is needed, as later macro definitions
> > will leverage that.

Yes, sorry. I got things muddled up there.

> > > And...
> > >
> > > ... avoid the need for changes like the two above.
> > 
> > This part is correct/what I meant ;)
> > 
> 
> Hi Paolo/Simon
> 
> Thanks for your reviews. Ideally, I would want to maintain regaddr as u16 since for clockmatrix addressing, it is only the lower 8bit of the whole 32bit address while module is upper 24bit. On the other hand, for some simple cases, where only one register in a module, their addresses are defined by module only without regaddr such as sync_ctrl0/1
> 
> Overall, I still want to differentiate between module and regaddr and don't wanna mix them up.

My reading is that this patch reverses the usage of module and regaddr.
F.e. the following hunk:

@@ -553,11 +554,11 @@ static int _sync_pll_output(struct idtcm *idtcm,
	val = SYNCTRL1_MASTER_SYNC_RST;

	/* Place master sync in reset */
	err = idtcm_write(idtcm, 0, sync_ctrl1, &val, sizeof(val));
	err = idtcm_write(idtcm, sync_ctrl1, 0, &val, sizeof(val));
	if (err)
		return err;

	err = idtcm_write(idtcm, 0, sync_ctrl0, &sync_src, sizeof(sync_src));
	err = idtcm_write(idtcm, sync_ctrl0, 0, &sync_src, sizeof(sync_src));
	if (err)
		return err;

If that is really intended I think it needs to be explained, or possibly
a separate patch.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ