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]
Date: Fri, 5 May 2023 09:25:56 +0800
From: Feiyang Chen <chris.chenfeiyang@...il.com>
To: Jakub Kicinski <kuba@...nel.org>
Cc: Giuseppe Cavallaro <peppe.cavallaro@...com>, Alexandre Torgue <alexandre.torgue@...s.st.com>, 
	Jose Abreu <joabreu@...opsys.com>, netdev@...r.kernel.org
Subject: Re: Help needed: supporting new device with unique register bitfields

On Tue, Apr 25, 2023 at 3:54 AM Jakub Kicinski <kuba@...nel.org> wrote:
>
> On Sun, 23 Apr 2023 16:19:11 +0800 Feiyang Chen wrote:
> > We are hoping to add support for a new device which shares almost
> > identical logic with dwmac1000 (dwmac_lib.c, dwmac1000_core.c, and
> > dwmac1000_dma.c), but with significant differences in the register
> > bitfields (dwmac_dma.h and dwmac1000.h).
> >
> > We are seeking guidance on the best approach to support this new
> > device. Any advice on how to proceed would be greatly appreciated.
> >
> > Thank you for your time and expertise.
>
> There's no recipe on how to support devices with different register
> layout :(  You'll need to find the right balance of (1) indirect calls,
> (2) if conditions and (3) static description data that's right for you.
>
> Static description data (e.g. putting register addresses in a struct
> and using the members of that struct rather than #defines) is probably
> the best but the least flexible.
>
> Adding the stmmac maintainers.

Hi, Jakub,

Thank you very much!

Thanks,
Feiyang

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ