<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/net/ethernet/sun, branch linux-4.9.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.9.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.9.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2022-09-28T08:55:46Z</updated>
<entry>
<title>net: sunhme: Fix packet reception for len &lt; RX_COPY_THRESHOLD</title>
<updated>2022-09-28T08:55:46Z</updated>
<author>
<name>Sean Anderson</name>
</author>
<published>2022-09-20T23:50:18Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=0e35e8f8f442ce201131d87b0c5c6dcbb18686e2'/>
<id>urn:sha1:0e35e8f8f442ce201131d87b0c5c6dcbb18686e2</id>
<content type='text'>
[ Upstream commit 878e2405710aacfeeb19364c300f38b7a9abfe8f ]

There is a separate receive path for small packets (under 256 bytes).
Instead of allocating a new dma-capable skb to be used for the next packet,
this path allocates a skb and copies the data into it (reusing the existing
sbk for the next packet). There are two bytes of junk data at the beginning
of every packet. I believe these are inserted in order to allow aligned DMA
and IP headers. We skip over them using skb_reserve. Before copying over
the data, we must use a barrier to ensure we see the whole packet. The
current code only synchronizes len bytes, starting from the beginning of
the packet, including the junk bytes. However, this leaves off the final
two bytes in the packet. Synchronize the whole packet.

To reproduce this problem, ping a HME with a payload size between 17 and
214

	$ ping -s 17 &lt;hme_address&gt;

which will complain rather loudly about the data mismatch. Small packets
(below 60 bytes on the wire) do not have this issue. I suspect this is
related to the padding added to increase the minimum packet size.

Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Signed-off-by: Sean Anderson &lt;seanga2@gmail.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Link: https://lore.kernel.org/r/20220920235018.1675956-1-seanga2@gmail.com
Signed-off-by: Jakub Kicinski &lt;kuba@kernel.org&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>ethernet: sun: Free the coherent when failing in probing</title>
<updated>2022-04-20T07:06:28Z</updated>
<author>
<name>Zheyu Ma</name>
</author>
<published>2022-03-05T14:55:04Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a322170ed71705d975c674886724f2bb43c17189'/>
<id>urn:sha1:a322170ed71705d975c674886724f2bb43c17189</id>
<content type='text'>
[ Upstream commit bb77bd31c281f70ec77c9c4f584950a779e05cf8 ]

When the driver fails to register net device, it should free the DMA
region first, and then do other cleanup.

Signed-off-by: Zheyu Ma &lt;zheyuma97@gmail.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>NIU: fix incorrect error return, missed in previous revert</title>
<updated>2021-08-04T09:58:03Z</updated>
<author>
<name>Paul Jakma</name>
</author>
<published>2021-07-23T15:13:04Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5c2b6075cee06850cbc1d867346e430e217c5d39'/>
<id>urn:sha1:5c2b6075cee06850cbc1d867346e430e217c5d39</id>
<content type='text'>
commit 15bbf8bb4d4ab87108ecf5f4155ec8ffa3c141d6 upstream.

Commit 7930742d6, reverting 26fd962, missed out on reverting an incorrect
change to a return value.  The niu_pci_vpd_scan_props(..) == 1 case appears
to be a normal path - treating it as an error and return -EINVAL was
breaking VPD_SCAN and causing the driver to fail to load.

Fix, so my Neptune card works again.

Cc: Kangjie Lu &lt;kjlu@umn.edu&gt;
Cc: Shannon Nelson &lt;shannon.lee.nelson@gmail.com&gt;
Cc: David S. Miller &lt;davem@davemloft.net&gt;
Cc: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Cc: stable &lt;stable@vger.kernel.org&gt;
Fixes: 7930742d ('Revert "niu: fix missing checks of niu_pci_eeprom_read"')
Signed-off-by: Paul Jakma &lt;paul@jakma.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>ethernet: sun: niu: fix missing checks of niu_pci_eeprom_read()</title>
<updated>2021-05-26T09:29:08Z</updated>
<author>
<name>Du Cheng</name>
</author>
<published>2021-05-03T11:56:50Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=3b3aa39062b0d9ff41e518fb9ff832298a11ab06'/>
<id>urn:sha1:3b3aa39062b0d9ff41e518fb9ff832298a11ab06</id>
<content type='text'>
commit e6e337708c22f80824b82d4af645f20715730ad0 upstream.

niu_pci_eeprom_read() may fail, so add checks to its return value and
propagate the error up the callstack.

An examination of the callstack up to niu_pci_eeprom_read shows that:

niu_pci_eeprom_read() // returns int
    niu_pci_vpd_scan_props() // returns int
        niu_pci_vpd_fetch() // returns *void*
            niu_get_invariants() // returns int

since niu_pci_vpd_fetch() returns void which breaks the bubbling up,
change its return type to int so that error is propagated upwards.

Signed-off-by: Du Cheng &lt;ducheng2@gmail.com&gt;
Cc: Shannon Nelson &lt;shannon.lee.nelson@gmail.com&gt;
Cc: David S. Miller &lt;davem@davemloft.net&gt;
Cc: stable &lt;stable@vger.kernel.org&gt;
Link: https://lore.kernel.org/r/20210503115736.2104747-24-gregkh@linuxfoundation.org
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>Revert "niu: fix missing checks of niu_pci_eeprom_read"</title>
<updated>2021-05-26T09:29:08Z</updated>
<author>
<name>Greg Kroah-Hartman</name>
</author>
<published>2021-05-03T11:56:49Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=4ff4a3587bb84826420145020ebb8212807e0026'/>
<id>urn:sha1:4ff4a3587bb84826420145020ebb8212807e0026</id>
<content type='text'>
commit 7930742d6a0ff091c85b92ef4e076432d8d8cb79 upstream.

This reverts commit 26fd962bde0b15e54234fe762d86bc0349df1de4.

Because of recent interactions with developers from @umn.edu, all
commits from them have been recently re-reviewed to ensure if they were
correct or not.

Upon review, this commit was found to be incorrect for the reasons
below, so it must be reverted.  It will be fixed up "correctly" in a
later kernel change.

The change here was incorrect.  While it is nice to check if
niu_pci_eeprom_read() succeeded or not when using the data, any error
that might have happened was not propagated upwards properly, causing
the kernel to assume that these reads were successful, which results in
invalid data in the buffer that was to contain the successfully read
data.

Cc: Kangjie Lu &lt;kjlu@umn.edu&gt;
Cc: Shannon Nelson &lt;shannon.lee.nelson@gmail.com&gt;
Cc: David S. Miller &lt;davem@davemloft.net&gt;
Fixes: 26fd962bde0b ("niu: fix missing checks of niu_pci_eeprom_read")
Cc: stable &lt;stable@vger.kernel.org&gt;
Link: https://lore.kernel.org/r/20210503115736.2104747-23-gregkh@linuxfoundation.org
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>sun/niu: fix wrong RXMAC_BC_FRM_CNT_COUNT count</title>
<updated>2021-03-30T12:41:39Z</updated>
<author>
<name>Denis Efremov</name>
</author>
<published>2021-03-05T17:02:12Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=54567920b3bcfd704f27b818525ef01872a5e9a1'/>
<id>urn:sha1:54567920b3bcfd704f27b818525ef01872a5e9a1</id>
<content type='text'>
[ Upstream commit 155b23e6e53475ca3b8c2a946299b4d4dd6a5a1e ]

RXMAC_BC_FRM_CNT_COUNT added to mp-&gt;rx_bcasts twice in a row
in niu_xmac_interrupt(). Remove the second addition.

Signed-off-by: Denis Efremov &lt;efremov@linux.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>sunvnet: use icmp_ndo_send helper</title>
<updated>2021-03-03T16:44:46Z</updated>
<author>
<name>Jason A. Donenfeld</name>
</author>
<published>2020-02-11T19:47:07Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b7124be76322a09ed5ff76ae516356d9459a9995'/>
<id>urn:sha1:b7124be76322a09ed5ff76ae516356d9459a9995</id>
<content type='text'>
commit 67c9a7e1e3ac491b5df018803639addc36f154ba upstream.

Because sunvnet is calling icmp from network device context, it should use
the ndo helper so that the rate limiting applies correctly. While we're
at it, doing the additional route lookup before calling icmp_ndo_send is
superfluous, since this is the job of the icmp code in the first place.

Signed-off-by: Jason A. Donenfeld &lt;Jason@zx2c4.com&gt;
Cc: Shannon Nelson &lt;shannon.nelson@oracle.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>net: sun: fix missing release regions in cas_init_one().</title>
<updated>2020-06-03T06:16:32Z</updated>
<author>
<name>Qiushi Wu</name>
</author>
<published>2020-05-22T21:50:27Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=6a6237db07083785de882a3147f76bba78d372c0'/>
<id>urn:sha1:6a6237db07083785de882a3147f76bba78d372c0</id>
<content type='text'>
commit 5a730153984dd13f82ffae93d7170d76eba204e9 upstream.

In cas_init_one(), "pdev" is requested by "pci_request_regions", but it
was not released after a call of the function “pci_write_config_byte”
failed. Thus replace the jump target “err_write_cacheline” by
"err_out_free_res".

Fixes: 1f26dac32057 ("[NET]: Add Sun Cassini driver.")
Signed-off-by: Qiushi Wu &lt;wu000273@umn.edu&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>niu: fix missing checks of niu_pci_eeprom_read</title>
<updated>2019-02-12T18:44:58Z</updated>
<author>
<name>Kangjie Lu</name>
</author>
<published>2018-12-25T07:56:14Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=63e311153b66fb36eb448e65b8bca5c1dbf1c28e'/>
<id>urn:sha1:63e311153b66fb36eb448e65b8bca5c1dbf1c28e</id>
<content type='text'>
[ Upstream commit 26fd962bde0b15e54234fe762d86bc0349df1de4 ]

niu_pci_eeprom_read() may fail, so we should check its return value
before using the read data.

Signed-off-by: Kangjie Lu &lt;kjlu@umn.edu&gt;
Acked-by: Shannon Nelson &lt;shannon.lee.nelson@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>net: sungem: fix rx checksum support</title>
<updated>2018-07-22T12:27:37Z</updated>
<author>
<name>Eric Dumazet</name>
</author>
<published>2018-06-20T02:18:50Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=32490f4d76ed005b35d826ee4807dafad95f9ba8'/>
<id>urn:sha1:32490f4d76ed005b35d826ee4807dafad95f9ba8</id>
<content type='text'>
[ Upstream commit 12b03558cef6d655d0d394f5e98a6fd07c1f6c0f ]

After commit 88078d98d1bb ("net: pskb_trim_rcsum() and CHECKSUM_COMPLETE
are friends"), sungem owners reported the infamous "eth0: hw csum failure"
message.

CHECKSUM_COMPLETE has in fact never worked for this driver, but this
was masked by the fact that upper stacks had to strip the FCS, and
therefore skb-&gt;ip_summed was set back to CHECKSUM_NONE before
my recent change.

Driver configures a number of bytes to skip when the chip computes
the checksum, and for some reason only half of the Ethernet header
was skipped.

Then a second problem is that we should strip the FCS by default,
unless the driver is updated to eventually support NETIF_F_RXFCS in
the future.

Finally, a driver should check if NETIF_F_RXCSUM feature is enabled
or not, so that the admin can turn off rx checksum if wanted.

Many thanks to Andreas Schwab and Mathieu Malaterre for their
help in debugging this issue.

Signed-off-by: Eric Dumazet &lt;edumazet@google.com&gt;
Reported-by: Meelis Roos &lt;mroos@linux.ee&gt;
Reported-by: Mathieu Malaterre &lt;malat@debian.org&gt;
Reported-by: Andreas Schwab &lt;schwab@linux-m68k.org&gt;
Tested-by: Andreas Schwab &lt;schwab@linux-m68k.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
</feed>
