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  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 10 Oct 2019 19:20:47 +0000
From:   Vijay Khemka <vijaykhemka@...com>
To:     "David S. Miller" <davem@...emloft.net>,
        Florian Fainelli <f.fainelli@...il.com>,
        YueHaibing <yuehaibing@...wei.com>, Andrew Lunn <andrew@...n.ch>,
        Kate Stewart <kstewart@...uxfoundation.org>,
        "Mauro Carvalho Chehab" <mchehab+samsung@...nel.org>,
        Luis Chamberlain <mcgrof@...nel.org>,
        Thomas Gleixner <tglx@...utronix.de>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        Benjamin Herrenschmidt <benh@...nel.crashing.org>
CC:     "openbmc @ lists . ozlabs . org" <openbmc@...ts.ozlabs.org>,
        "joel@....id.au" <joel@....id.au>,
        "linux-aspeed@...ts.ozlabs.org" <linux-aspeed@...ts.ozlabs.org>,
        Sai Dasari <sdasari@...com>
Subject: Re: [PATCH v2] ftgmac100: Disable HW checksum generation on AST2500

Resending this patch again. 

´╗┐On 9/11/19, 1:05 PM, "Vijay Khemka" <vijaykhemka@...com> wrote:

    HW checksum generation is not working for AST2500, specially with IPV6
    over NCSI. All TCP packets with IPv6 get dropped. By disabling this
    it works perfectly fine with IPV6. As it works for IPV4 so enabled
    hw checksum back for IPV4.
    
    Verified with IPV6 enabled and can do ssh.
    
    Signed-off-by: Vijay Khemka <vijaykhemka@...com>
    ---
    Changes since v1:
     Enabled IPV4 hw checksum generation as it works for IPV4.
    
     drivers/net/ethernet/faraday/ftgmac100.c | 13 ++++++++++++-
     1 file changed, 12 insertions(+), 1 deletion(-)
    
    diff --git a/drivers/net/ethernet/faraday/ftgmac100.c b/drivers/net/ethernet/faraday/ftgmac100.c
    index 030fed65393e..0255a28d2958 100644
    --- a/drivers/net/ethernet/faraday/ftgmac100.c
    +++ b/drivers/net/ethernet/faraday/ftgmac100.c
    @@ -1842,8 +1842,19 @@ static int ftgmac100_probe(struct platform_device *pdev)
     	/* AST2400  doesn't have working HW checksum generation */
     	if (np && (of_device_is_compatible(np, "aspeed,ast2400-mac")))
     		netdev->hw_features &= ~NETIF_F_HW_CSUM;
    +
    +	/* AST2500 doesn't have working HW checksum generation for IPV6
    +	 * but it works for IPV4, so disabling hw checksum and enabling
    +	 * it for only IPV4.
    +	 */
    +	if (np && (of_device_is_compatible(np, "aspeed,ast2500-mac"))) {
    +		netdev->hw_features &= ~NETIF_F_HW_CSUM;
    +		netdev->hw_features |= NETIF_F_IP_CSUM;
    +	}
    +
     	if (np && of_get_property(np, "no-hw-checksum", NULL))
    -		netdev->hw_features &= ~(NETIF_F_HW_CSUM | NETIF_F_RXCSUM);
    +		netdev->hw_features &= ~(NETIF_F_HW_CSUM | NETIF_F_RXCSUM
    +					 | NETIF_F_IP_CSUM);
     	netdev->features |= netdev->hw_features;
     
     	/* register network device */
    -- 
    2.17.1
    
    

Powered by blists - more mailing lists