<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/drivers/net/ethernet/dlink/dl2k.c, branch linux-6.18.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.</subtitle>
<id>https://universe.0xinfinity.dev/distro/kernel/atom?h=linux-6.18.y</id>
<link rel='self' href='https://universe.0xinfinity.dev/distro/kernel/atom?h=linux-6.18.y'/>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/'/>
<updated>2025-10-22T01:38:38Z</updated>
<entry>
<title>net: dlink: use dev_kfree_skb_any instead of dev_kfree_skb</title>
<updated>2025-10-22T01:38:38Z</updated>
<author>
<name>Yeounsu Moon</name>
<email>yyyynoom@gmail.com</email>
</author>
<published>2025-10-19T07:55:40Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=5523508258d390fd55b25c1c0f99c092f23a39e9'/>
<id>urn:sha1:5523508258d390fd55b25c1c0f99c092f23a39e9</id>
<content type='text'>
Replace `dev_kfree_skb()` with `dev_kfree_skb_any()` in `start_xmit()`
which can be called from netpoll (hard IRQ) and from other contexts.

Also, `np-&gt;link_status` can be changed at any time by interrupt handler.

  &lt;idle&gt;-0       [011] dNh4.  4541.754603: start_xmit &lt;-netpoll_start_xmit
  &lt;idle&gt;-0       [011] dNh4.  4541.754622: &lt;stack trace&gt;
 =&gt; [FTRACE TRAMPOLINE]
 =&gt; start_xmit
 =&gt; netpoll_start_xmit
 =&gt; netpoll_send_skb
 =&gt; write_msg
 =&gt; console_flush_all
 =&gt; console_unlock
 =&gt; vprintk_emit
 =&gt; _printk
 =&gt; rio_interrupt
 =&gt; __handle_irq_event_percpu
 =&gt; handle_irq_event
 =&gt; handle_fasteoi_irq
 =&gt; __common_interrupt
 =&gt; common_interrupt
 =&gt; asm_common_interrupt
 =&gt; mwait_idle
 =&gt; default_idle_call
 =&gt; do_idle
 =&gt; cpu_startup_entry
 =&gt; start_secondary
 =&gt; common_startup_64

This issue can occur when the link state changes from off to on
(e.g., plugging or unplugging the LAN cable) while transmitting a
packet. If the skb has a destructor, a warning message may be
printed in this situation.

-&gt; consume_skb (dev_kfree_skb())
  -&gt; __kfree_skb()
    -&gt; skb_release_all()
      -&gt; skb_release_head_state(skb)
	 if (skb-&gt;destructor) {
	         DEBUG_NET_WARN_ON_ONCE(in_hardirq());
		 skb-&gt;destructor(skb);
	 }

Found by inspection.

Signed-off-by: Yeounsu Moon &lt;yyyynoom@gmail.com&gt;
Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Tested-on: D-Link DGE-550T Rev-A3
Reviewed-by: Simon Horman &lt;horms@kernel.org&gt;
Link: https://patch.msgid.link/20251019075540.55697-1-yyyynoom@gmail.com
Signed-off-by: Jakub Kicinski &lt;kuba@kernel.org&gt;
</content>
</entry>
<entry>
<title>net: dlink: handle dma_map_single() failure properly</title>
<updated>2025-10-12T18:02:16Z</updated>
<author>
<name>Yeounsu Moon</name>
<email>yyyynoom@gmail.com</email>
</author>
<published>2025-10-09T15:57:16Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=65946eac6d888d50ae527c4e5c237dbe5cc3a2f2'/>
<id>urn:sha1:65946eac6d888d50ae527c4e5c237dbe5cc3a2f2</id>
<content type='text'>
There is no error handling for `dma_map_single()` failures.

Add error handling by checking `dma_mapping_error()` and freeing
the `skb` using `dev_kfree_skb()` (process context) when it fails.

Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Signed-off-by: Yeounsu Moon &lt;yyyynoom@gmail.com&gt;
Tested-on: D-Link DGE-550T Rev-A3
Suggested-by: Simon Horman &lt;horms@kernel.org&gt;
Reviewed-by: Simon Horman &lt;horms@kernel.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: dlink: handle copy_thresh allocation failure</title>
<updated>2025-09-30T01:47:49Z</updated>
<author>
<name>Yeounsu Moon</name>
<email>yyyynoom@gmail.com</email>
</author>
<published>2025-09-28T19:01:24Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=8169a6011c5fecc6cb1c3654c541c567d3318de8'/>
<id>urn:sha1:8169a6011c5fecc6cb1c3654c541c567d3318de8</id>
<content type='text'>
The driver did not handle failure of `netdev_alloc_skb_ip_align()`.
If the allocation failed, dereferencing `skb-&gt;protocol` could lead to
a NULL pointer dereference.

This patch tries to allocate `skb`. If the allocation fails, it falls
back to the normal path.

Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Suggested-by: Jakub Kicinski &lt;kuba@kernel.org&gt;
Tested-on: D-Link DGE-550T Rev-A3
Signed-off-by: Yeounsu Moon &lt;yyyynoom@gmail.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Link: https://patch.msgid.link/20250928190124.1156-1-yyyynoom@gmail.com
Signed-off-by: Jakub Kicinski &lt;kuba@kernel.org&gt;
</content>
</entry>
<entry>
<title>net: dlink: fix multicast stats being counted incorrectly</title>
<updated>2025-08-26T00:22:31Z</updated>
<author>
<name>Yeounsu Moon</name>
<email>yyyynoom@gmail.com</email>
</author>
<published>2025-08-23T18:29:24Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=007a5ffadc4fd51739527f1503b7cf048f31c413'/>
<id>urn:sha1:007a5ffadc4fd51739527f1503b7cf048f31c413</id>
<content type='text'>
`McstFramesRcvdOk` counts the number of received multicast packets, and
it reports the value correctly.

However, reading `McstFramesRcvdOk` clears the register to zero. As a
result, the driver was reporting only the packets since the last read,
instead of the accumulated total.

Fix this by updating the multicast statistics accumulatively instaed of
instantaneously.

Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Tested-on: D-Link DGE-550T Rev-A3
Signed-off-by: Yeounsu Moon &lt;yyyynoom@gmail.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Link: https://patch.msgid.link/20250823182927.6063-3-yyyynoom@gmail.com
Signed-off-by: Jakub Kicinski &lt;kuba@kernel.org&gt;
</content>
</entry>
<entry>
<title>Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net</title>
<updated>2025-06-12T17:09:10Z</updated>
<author>
<name>Jakub Kicinski</name>
<email>kuba@kernel.org</email>
</author>
<published>2025-06-12T17:08:24Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=535de528015b56e34a40a8e1eb1629fadf809a84'/>
<id>urn:sha1:535de528015b56e34a40a8e1eb1629fadf809a84</id>
<content type='text'>
Cross-merge networking fixes after downstream PR (net-6.16-rc2).

No conflicts or adjacent changes.

Signed-off-by: Jakub Kicinski &lt;kuba@kernel.org&gt;
</content>
</entry>
<entry>
<title>net: dlink: enable RMON MMIO access on supported devices</title>
<updated>2025-06-11T00:47:13Z</updated>
<author>
<name>Moon Yeounsu</name>
<email>yyyynoom@gmail.com</email>
</author>
<published>2025-06-10T00:01:30Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=7fc18f9476256c03755d93b1cec0d42cf64d850a'/>
<id>urn:sha1:7fc18f9476256c03755d93b1cec0d42cf64d850a</id>
<content type='text'>
Enable memory-mapped I/O access to RMON statistics registers for devices
known to work correctly. Currently, only the D-Link DGE-550T (`0x4000`)
with PCI revision A3 (`0x0c`) is allowed.

To avoid issues on other hardware, a runtime check was added to restrict
MMIO usage. The `MEM_MAPPING` macro was removed in favor of runtime
detection.

To access RMON registers, the code `dw32(RmonStatMask, 0x0007ffff);`
must also be skipped, so this patch conditionally disables it as well.

Tested-on: D-Link DGE-550T Rev-A3
Signed-off-by: Moon Yeounsu &lt;yyyynoom@gmail.com&gt;
Link: https://patch.msgid.link/20250610000130.49065-2-yyyynoom@gmail.com
Signed-off-by: Jakub Kicinski &lt;kuba@kernel.org&gt;
</content>
</entry>
<entry>
<title>treewide, timers: Rename from_timer() to timer_container_of()</title>
<updated>2025-06-08T07:07:37Z</updated>
<author>
<name>Ingo Molnar</name>
<email>mingo@kernel.org</email>
</author>
<published>2025-05-09T05:51:14Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=41cb08555c4164996d67c78b3bf1c658075b75f1'/>
<id>urn:sha1:41cb08555c4164996d67c78b3bf1c658075b75f1</id>
<content type='text'>
Move this API to the canonical timer_*() namespace.

[ tglx: Redone against pre rc1 ]

Signed-off-by: Ingo Molnar &lt;mingo@kernel.org&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Link: https://lore.kernel.org/all/aB2X0jCKQO56WdMt@gmail.com

</content>
</entry>
<entry>
<title>net: dlink: add synchronization for stats update</title>
<updated>2025-05-16T22:58:13Z</updated>
<author>
<name>Moon Yeounsu</name>
<email>yyyynoom@gmail.com</email>
</author>
<published>2025-05-15T07:53:31Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=12889ce926e9a9baf6b83d809ba316af539b89e2'/>
<id>urn:sha1:12889ce926e9a9baf6b83d809ba316af539b89e2</id>
<content type='text'>
This patch synchronizes code that accesses from both user-space
and IRQ contexts. The `get_stats()` function can be called from both
context.

`dev-&gt;stats.tx_errors` and `dev-&gt;stats.collisions` are also updated
in the `tx_errors()` function. Therefore, these fields must also be
protected by synchronized.

There is no code that accessses `dev-&gt;stats.tx_errors` between the
previous and updated lines, so the updating point can be moved.

Signed-off-by: Moon Yeounsu &lt;yyyynoom@gmail.com&gt;
Link: https://patch.msgid.link/20250515075333.48290-1-yyyynoom@gmail.com
Signed-off-by: Jakub Kicinski &lt;kuba@kernel.org&gt;
</content>
</entry>
<entry>
<title>net: dlink: Correct endianness handling of led_mode</title>
<updated>2025-04-29T18:50:38Z</updated>
<author>
<name>Simon Horman</name>
<email>horms@kernel.org</email>
</author>
<published>2025-04-25T15:50:47Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=e7e5ae71831c44d58627a991e603845a2fed2cab'/>
<id>urn:sha1:e7e5ae71831c44d58627a991e603845a2fed2cab</id>
<content type='text'>
As it's name suggests, parse_eeprom() parses EEPROM data.

This is done by reading data, 16 bits at a time as follows:

	for (i = 0; i &lt; 128; i++)
                ((__le16 *) sromdata)[i] = cpu_to_le16(read_eeprom(np, i));

sromdata is at the same memory location as psrom.
And the type of psrom is a pointer to struct t_SROM.

As can be seen in the loop above, data is stored in sromdata, and thus psrom,
as 16-bit little-endian values.

However, the integer fields of t_SROM are host byte order integers.
And in the case of led_mode this leads to a little endian value
being incorrectly treated as host byte order.

Looking at rio_set_led_mode, this does appear to be a bug as that code
masks led_mode with 0x1, 0x2 and 0x8. Logic that would be effected by a
reversed byte order.

This problem would only manifest on big endian hosts.

Found by inspection while investigating a sparse warning
regarding the crc field of t_SROM.

I believe that warning is a false positive. And although I plan
to send a follow-up to use little-endian types for other the integer
fields of PSROM_t I do not believe that will involve any bug fixes.

Compile tested only.

Fixes: c3f45d322cbd ("dl2k: Add support for IP1000A-based cards")
Signed-off-by: Simon Horman &lt;horms@kernel.org&gt;
Link: https://patch.msgid.link/20250425-dlink-led-mode-v1-1-6bae3c36e736@kernel.org
Signed-off-by: Jakub Kicinski &lt;kuba@kernel.org&gt;
</content>
</entry>
<entry>
<title>treewide: Switch/rename to timer_delete[_sync]()</title>
<updated>2025-04-05T08:30:12Z</updated>
<author>
<name>Thomas Gleixner</name>
<email>tglx@linutronix.de</email>
</author>
<published>2025-04-05T08:17:26Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=8fa7292fee5c5240402371ea89ab285ec856c916'/>
<id>urn:sha1:8fa7292fee5c5240402371ea89ab285ec856c916</id>
<content type='text'>
timer_delete[_sync]() replaces del_timer[_sync](). Convert the whole tree
over and remove the historical wrapper inlines.

Conversion was done with coccinelle plus manual fixups where necessary.

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Signed-off-by: Ingo Molnar &lt;mingo@kernel.org&gt;
</content>
</entry>
</feed>
