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: <dleftjblfxl3jt.fsf%l.stelmach@samsung.com>
Date:   Mon, 16 Nov 2020 16:33:26 +0100
From:   Lukasz Stelmach <l.stelmach@...sung.com>
To:     Jakub Kicinski <kuba@...nel.org>
Cc:     Andrew Lunn <andrew@...n.ch>, jim.cromie@...il.com,
        Heiner Kallweit <hkallweit1@...il.com>,
        "David S. Miller" <davem@...emloft.net>,
        Rob Herring <robh+dt@...nel.org>,
        Kukjin Kim <kgene@...nel.org>,
        Krzysztof Kozlowski <krzk@...nel.org>,
        Russell King <linux@...linux.org.uk>, netdev@...r.kernel.org,
        devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
        linux-arm-kernel@...ts.infradead.org,
        linux-samsung-soc@...r.kernel.org,
        Bartłomiej Żolnierkiewicz 
        <b.zolnierkie@...sung.com>,
        Marek Szyprowski <m.szyprowski@...sung.com>
Subject: Re: [PATCH v6 3/5] net: ax88796c: ASIX AX88796C SPI Ethernet
 Adapter Driver

It was <2020-11-13 pią 12:35>, when Jakub Kicinski wrote:
> On Thu, 12 Nov 2020 12:51:04 +0100 Łukasz Stelmach wrote:
>> ASIX AX88796[1] is a versatile ethernet adapter chip, that can be
>> connected to a CPU with a 8/16-bit bus or with an SPI. This driver
>> supports SPI connection.
>> 
>> The driver has been ported from the vendor kernel for ARTIK5[2]
>> boards. Several changes were made to adapt it to the current kernel
>> which include:
>> 
>> + updated DT configuration,
>> + clock configuration moved to DT,
>> + new timer, ethtool and gpio APIs,
>> + dev_* instead of pr_* and custom printk() wrappers,
>> + removed awkward vendor power managemtn.
>> + introduced ethtool tunable to control SPI compression
>> 
>> [1]
>> https://protect2.fireeye.com/v1/url?k=96d0e769-c94bde24-96d16c26-0cc47aa8f5ba-09ef5c65a6139da8&q=1&e=472aea40-d885-45aa-bc04-66e70be69a4c&u=https%3A%2F%2Fwww.asix.com.tw%2Fproducts.php%3Fop%3DpItemdetail%26PItemID%3D104%3B65%3B86%26PLine%3D65
>> [2]
>> https://protect2.fireeye.com/v1/url?k=3834941b-67afad56-38351f54-0cc47aa8f5ba-067355624cc12466&q=1&e=472aea40-d885-45aa-bc04-66e70be69a4c&u=https%3A%2F%2Fgit.tizen.org%2Fcgit%2Fprofile%2Fcommon%2Fplatform%2Fkernel%2Flinux-3.10-artik%2F
>> 
>> The other ax88796 driver is for NE2000 compatible AX88796L chip. These
>> chips are not compatible. Hence, two separate drivers are required.
>> 
>> Signed-off-by: Łukasz Stelmach <l.stelmach@...sung.com>
>
> Please make sure the new code builds cleanly with W=1 C=1
>
> ../drivers/net/ethernet/asix/ax88796c_ioctl.c:221:19: warning: initialized field overwritten [-Woverride-init]
>   221 |  .get_msglevel  = ax88796c_ethtool_getmsglevel,
>       |                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
> ../drivers/net/ethernet/asix/ax88796c_ioctl.c:221:19: note: (near initialization for ‘ax88796c_ethtool_ops.get_msglevel’)
> ../drivers/net/ethernet/asix/ax88796c_ioctl.c:222:19: warning: initialized field overwritten [-Woverride-init]
>   222 |  .set_msglevel  = ax88796c_ethtool_setmsglevel,
>       |                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
> ../drivers/net/ethernet/asix/ax88796c_ioctl.c:222:19: note: (near initialization for ‘ax88796c_ethtool_ops.set_msglevel’)
> In file included from ../drivers/net/ethernet/asix/ax88796c_main.h:15,
>                  from ../drivers/net/ethernet/asix/ax88796c_ioctl.c:16:
> ../drivers/net/ethernet/asix/ax88796c_spi.h:25:17: warning: ‘tx_cmd_buf’ defined but not used [-Wunused-const-variable=]
>    25 | static const u8 tx_cmd_buf[4] = {AX_SPICMD_WRITE_TXQ, 0xFF, 0xFF, 0xFF};
>       |                 ^~~~~~~~~~

I fixed the problems reported by W=1, but I am afraid I can't do
anything about C=1. sparse is is reporting

[...]
./include/linux/atomic-fallback.h:266:16: error: Expected ; at end ofdeclaration
./include/linux/atomic-fallback.h:266:16: error: got ret
./include/linux/atomic-fallback.h:267:1: error: Expected ; at the end of type declaration
./include/linux/atomic-fallback.h:267:1: error: too many errors
Segmentation fault

in the headers and gets killed.

-- 
Łukasz Stelmach
Samsung R&D Institute Poland
Samsung Electronics

Download attachment "signature.asc" of type "application/pgp-signature" (488 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ