it message.
Ben.
--
Ben Hutchings, Software Developer Codethink Ltd
https://www.codethink.co.uk/ Dale House, 35 Dale Street
Manchester, M1 2HF, United Kingdom
security-4.4.mbox
Description: application/mbox
it message.
Ben.
--
Ben Hutchings, Software Developer Codethink Ltd
https://www.codethink.co.uk/ Dale House, 35 Dale Street
Manchester, M1 2HF, United Kingdom
security-4.9.mbox
Description: application/mbox
On Sun, 2020-08-02 at 22:44 +0200, Thorsten Glaser wrote:
> On Sun, 2 Aug 2020, Ben Hutchings wrote:
>
> > The RFC says that the IPV6_TCLASS option's value is an int, and that
>
> for setsockopt (“option's”), not cmsg
>
> > No, the wording is *not* clear.
&
On Sun, 2020-08-02 at 19:29 +, Thorsten Glaser wrote:
> Ben Hutchings dixit:
>
> >ip(7) also doesn't document IP_PKTOPIONS.
>
> Hmm, I don’t use IP_PKTOPIONS though. I’m not exactly sure I found
> the correct place in the kernel for what I do.
The first inst
ity is to avoid breaking currently working user-space. That
means that ugly and inconsistent APIs won't get fixed if it causes a
regression for the programs people actually use. If the API never
worked like it was supposed to on some architectures, that's not a
regression, and is lower p
On Mon, 2020-05-18 at 16:47 +, Saeed Mahameed wrote:
> On Sun, 2020-05-17 at 18:20 +0100, Ben Hutchings wrote:
> > mlx4_en_get_module_eeprom() returns 0 even if it fails. This results
> > in copying an uninitialised (or partly initialised) buffer back to
> > user-space.
avoid a
regression when reading modules with this problem.
* In other error cases, the error code is propagated.
Reported-by: Yannis Aribaud
References: https://bugs.debian.org/960702
Fixes: 7202da8b7f71 ("ethtool, net/mlx4_en: Cable info, get_module_info/...")
Signed-off-by: Ben
04fd22200: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
fb
[ 64.049993]
==
Ben.
--
Ben Hutchings
The world is coming to an end. Please log off.
signature.asc
Description: This is a digitally signed message part
? If not, is every driver that does TSO
expected to check this?
Also, should these fixes go to stable? I'm not sure whether you're
still handling stable patches for any of the unfixed versions (< 4.16)
now.
Ben.
--
Ben Hutchings, Software Developer
ej Żenczykowski
> ---
> ethtool-copy.h | 6 ++
> 1 file changed, 6 insertions(+)
>
> diff --git a/ethtool-copy.h b/ethtool-copy.h
> index 6bfbb85f9402..7772a4970987 100644
> --- a/ethtool-copy.h
> +++ b/ethtool-copy.h
> @@ -14,6 +14,12 @@
> #ifndef _LINUX_ET
+2076,7 @@ static int do_gchannels(struct cmd_context *ctx)
>
> static int do_gcoalesce(struct cmd_context *ctx)
> {
> - struct ethtool_coalesce ecoal;
> + struct ethtool_coalesce ecoal = {};
> int err;
>
> if (ctx->argc != 0)
--
Ben Hutchings
I
On Fri, 2018-11-23 at 21:10 +0100, Daniel Borkmann wrote:
> On 11/23/2018 07:34 PM, Ben Hutchings wrote:
> > User-space does not have access to the patched eBPF code, but we
> > need to be able to test that patches are being applied. Therefore
> > log distinct messages for ea
This is needed to test that code is being patched when it should be.
Signed-off-by: Ben Hutchings
---
tools/testing/selftests/bpf/test_verifier.c | 11 ++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/tools/testing/selftests/bpf/test_verifier.c
b/tools/testing
Test that the defence added by commit af86ca4e3088 "bpf: Prevent
memory disambiguation attack" is actually being applied.
Signed-off-by: Ben Hutchings
---
tools/testing/selftests/bpf/test_verifier.c | 15 +++
1 file changed, 15 insertions(+)
diff --git a/tools/testing/sel
User-space does not have access to the patched eBPF code, but we
need to be able to test that patches are being applied. Therefore
log distinct messages for each case that requires patching.
Signed-off-by: Ben Hutchings
---
kernel/bpf/verifier.c | 13 +
1 file changed, 13
This series adds log messages for all patching done by the verifier,
and a test case to verify that the patch to defend against SSB
exploitation is applied where needed.
Ben.
Ben Hutchings (3):
bpf/verifier: Log instruction patching when verbose logging is enabled
selftests/bpf: Add the
) define
CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS, which seems to imply that
NET_IP_ALIGN should be 0.
Remove the overriding definitions for ppc64 and x86 and define
NET_IP_ALIGN solely based on CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS.
Signed-off-by: Ben Hutchings
---
arch/powerpc/include/asm/processor.h
o this (only non-commercial
distributors can do that). So the source needs to be published too.
Adding the complete Linux kernel source code to linux-firmware.git
doesn't seem like a sensible step, so maybe this particular firmware
needs to live elsewhere.
Ben.
--
Ben Hutchings
For every complex problem
there is a solution that is simple, neat, and wrong.
signature.asc
Description: This is a digitally signed message part
> [2]
> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=5c25f65fd1e42685f7ccd80e0621829c105785d9
> [3]
> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=0ad646c81b2182f7fa67ec0c8c825e0ee165696d
> [4] https://www.spinics.net/lists/netdev/m
The driver-internal string operations are only ever used for
statistics, so remove the stringset parameters and rename them
accordingly.
Signed-off-by: Ben Hutchings
---
drivers/net/ethernet/hisilicon/hns/hnae.h | 13
drivers/net/ethernet/hisilicon/hns/hns_ae_adapt.c | 37
r any stringset other than ETH_SS_STATS.
Fixes: 511e6bc071db ("net: add Hisilicon Network Subsystem DSAF support")
Fixes: 412b65d15a7f ("net: hns: fix ethtool_get_strings overflow ...")
Signed-off-by: Ben Hutchings
---
drivers/net/ethernet/hisilicon/hns/hns_ethtool.c | 17 +
Please queue up this commit for stable:
69c64866ce07 dccp: CVE-2017-8824: use-after-free in DCCP code
Ben.
--
Ben Hutchings
Software Developer, Codethink Ltd.
ot updated, so it
currently returns 0 for all sockets for which IPV6_AUTOFLOWLABEL is
not explicitly enabled. Fix it to return the effective value, whether
that has been set at the socket or net namespace level.
Fixes: 513674b5a2c9 ("net: reevalulate autoflowlabel setting after sysctl ..."
On Wed, 2018-01-10 at 14:25 -0800, Cong Wang wrote:
> On Tue, Jan 9, 2018 at 10:21 AM, Ben Hutchings
> wrote:
> > Commit 15e668070a64 reordered the initialisation in inet6_init() to
> > fix a crash on an error path further down the call stack. It also
> > reordered clea
or crash in some error cases. Reorder
cleanup again to fix this.
Fixes: 15e668070a64 ("ipv6: reorder icmpv6_init() and ip6_mr_init()")
Signed-off-by: Ben Hutchings
---
This fix is untested and based only on my review of the earlier commit.
Ben.
net/ipv6/af_inet6.c | 6 +++---
1 file
ode around here was
largely rewritten in 4.14 by commit f1174f77b50c "bpf/verifier: rework
value tracking". The bug can be detected by the bpf/verifier sub-test
"pointer/scalar confusion in state equality check (way 1)".
Signed-off-by: Ben Hutchings
Cc: Edward Cree
Cc: Jan
On Tue, 2017-11-28 at 11:09 -0600, Steven J. Hill wrote:
> On 11/22/2017 07:40 PM, Ben Hutchings wrote:
> > On Tue, 2017-10-31 at 17:05 -0500, Steven J. Hill wrote:
> > > Hello.
> > >
> > > Would like to add firmware for our Octeon III PKI driver. Thanks.
>
ellanox/mlxsw_spectrum-13.1530.152.mfa2
Applied both of these, thanks.
Ben.
--
Ben Hutchings
When in doubt, use brute force. - Ken Thompson
signature.asc
Description: This is a digitally signed message part
liquidio/lio_210sv_nic.bin | Bin 1159096 -> 1163128 bytes
> liquidio/lio_23xx_nic.bin | Bin 1266528 -> 1271456 bytes
> liquidio/lio_410nv_nic.bin | Bin 1261080 -> 1265368 bytes
> 5 files changed, 4 insertions(+), 4 deletions(-)
Pulled, thanks.
Ben.
--
Ben Hutchings
When in d
> 1 file changed, 0 insertions(+), 0 deletions(-)
> create mode 100644 cavium/pki-cluster.bin
When adding a file you also need to update WHENCE to include its
copyright details.
Ben.
--
Ben Hutchings
When in doubt, use brute force. - Ken Thompson
signature.asc
Description: This is a digitally signed message part
00755 qed/qed_init_values_zipped-8.33.1.0.bin
[...]
Applied; sorry for the delay.
Ben.
--
Ben Hutchings
When in doubt, use brute force. - Ken Thompson
signature.asc
Description: This is a digitally signed message part
Good to know. I will send all three patches cherry-picked on top of the
> current 3.16 stable branch. Could you have a look please?
I've now queued these all up.
Ben.
--
Ben Hutchings
If you seem to know what you are doing, you'll be given more to do.
signature.asc
Description: This is a digitally signed message part
32_FORMAT) {
[...]
usbnet_read_cmd() doesn't do any byte-swapping, so it looks like
curr_ntb_format will have little-endian byte order (__le16 not u16).
The comparison will then need to be done using
le16_to_cpu(curr_ntb_format).
Ben.
--
Ben Hutchings
Software Developer, Codethink Ltd.
g the per-protocol handler, which means by default nothing leaks.
Only cases where msg_namelen is set but msg_name[] is not initialised
up to that length are a problem. I would have thought they were not
too hard to find and fix.
Ben.
> msg_sys->msg_name = &addr;
>
>
> -Support flow ID in aRFS flow.
>
> Signed-off-by: Rahul Verma
> ---
> qed/qed_init_values_zipped-8.30.16.0.bin | Bin 0 -> 837008 bytes
> 1 file changed, 0 insertions(+), 0 deletions(-)
> create mode 100755 qed/qed_init_values_zipped-8.30.16.0.bin
[...]
The new fil
2cad88269ea704eb270d7ac6e69e8a544c:
>
> cxgb4: update firmware to revision 1.16.63.0 (2017-09-27 08:14:29 -0700)
>
> --------
--
Ben Hutchings
Humour is the best antidote to reality.
signature.asc
Description: This is a digitally signed message part
to work through, but I will get to this
eventually.
Ben.
--
Ben Hutchings
Kids! Bringing about Armageddon can be dangerous. Do not attempt it in
your own home. - Terry Pratchett and Neil Gaiman, `Good Omens'
signature.asc
Description: This is a digitally signed message part
l.org/linus/d821a4c4d11ad160925dab2bb009b8444beff484
I think e1000 may still be unfixed, so this might be the same bug.
Ben.
--
Ben Hutchings
Unix is many things to many people,
but it's never been everything to anybody.
signature.asc
Description: This is a digitally signed message part
If I'm not mistaken, ipv6_gso_segment() now leaks segs if
ip6_find_1stfragopt() fails. I'm not sure whether the fix would be as
simple as adding a kfree_skb(segs) or whether more complex cleanup is
needed.
Ben.
--
Ben Hutchings
Lowery's Law:
If it jams, force it. I
xfrm6_find_1stfragopt() may now return an error code and we must
not treat it as a length.
Fixes: 2423496af35d ("ipv6: Prevent overrun when parsing v6 header options")
Signed-off-by: Ben Hutchings
---
Commits 2423496af35d "ipv6: Prevent overrun when parsing v6 header
options&qu
uests for those
older versions directly.
Please can you also send the pending fixes to Greg soon, as the
AF_PACKET issue is quite serious?
Ben.
--
Ben Hutchings
Software Developer, Codethink Ltd.
gt; +++ b/net/ipv4/ip_sockglue.c
> @@ -1009,7 +1009,8 @@ e_inval:
> */
> int ip_queue_rcv_skb(struct sock *sk, struct sk_buff *skb)
> {
> - if (!(inet_sk(sk)->cmsg_flags & IP_CMSG_PKTINFO))
> + if (!(inet_sk(sk)->cmsg_flags & IP_CMSG_PKTINFO) &&am
On Tue, 2017-03-21 at 00:33 +, Ben Hutchings wrote:
> On Sun, 2017-03-19 at 22:25 -0700, Eric Dumazet wrote:
> > On Mon, 2017-03-20 at 12:59 +0800, Anarcheuz Fritz wrote:
> > > Hi David,
> > >
> > >
> > > While working on some lega
mp; IP_CMSG_PKTINFO) &&
> + !IPCB(skb)->opt.optlen)
> skb_dst_drop(skb);
> return sock_queue_rcv_skb(sk, skb);
> }
Thanks to both of you; I'll queue this up for 3.2.
Ben.
--
Ben Hutchings
Power corrupts. Absolute power is kind of neat.
- John Lehman, Secretary of the US Navy
1981-1987
signature.asc
Description: This is a digitally signed message part
Signed-off-by: David S. Miller
Signed-off-by: Ben Hutchings
---
net/vmw_vsock/af_vsock.c | 21 +
1 file changed, 1 insertion(+), 20 deletions(-)
--- a/net/vmw_vsock/af_vsock.c
+++ b/net/vmw_vsock/af_vsock.c
@@ -1796,27 +1796,8 @@ vsock_stream_recvmsg(struct kiocb *kiocb
-s...@vger.kernel.org
Cc: netdev@vger.kernel.org
Acked-by: Neil Horman
Signed-off-by: David S. Miller
Signed-off-by: Ben Hutchings
---
net/sctp/socket.c | 5 -
1 file changed, 4 insertions(+), 1 deletion(-)
--- a/net/sctp/socket.c
+++ b/net/sctp/socket.c
@@ -4280,7 +4280,7 @@ static int sctp_gets
-s...@vger.kernel.org
Cc: netdev@vger.kernel.org
Acked-by: Neil Horman
Signed-off-by: David S. Miller
[bwh: Backported to 3.2: adjust context]
Signed-off-by: Ben Hutchings
---
net/sctp/socket.c | 5 -
1 file changed, 4 insertions(+), 1 deletion(-)
--- a/net/sctp/socket.c
+++ b/net/sctp/socket.c
:
> https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=c2ed1880fd61a998e3ce40254a99a2ad000f1a7d
[...]
--
Ben Hutchings
Reality is just a crutch for people who can't handle science fiction.
signature.asc
Description: This is a digitally signed message part
On Mon, Feb 06, 2017 at 04:09:18PM +, David Laight wrote:
> From: Ben Hutchings
[...]
> > + ret = usb_control_msg(dev->udev, usb_rcvctrlpipe(dev->udev, 0),
> > + RTL8150_REQ_GET_REGS, RTL8150_REQT_READ,
> > +
Signed-off-by: Ben Hutchings
---
drivers/net/usb/catc.c | 33 +
1 file changed, 17 insertions(+), 16 deletions(-)
diff --git a/drivers/net/usb/catc.c b/drivers/net/usb/catc.c
index 3daa41bdd4ea..985909eab72c 100644
--- a/drivers/net/usb/catc.c
+++ b/drivers/net
Allocating USB buffers on the stack is not portable, and no longer
works on x86_64 (with VMAP_STACK enabled as per default).
Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Signed-off-by: Ben Hutchings
---
drivers/net/usb/catc.c | 25 ++---
1 file changed, 18 insert
Allocating USB buffers on the stack is not portable, and no longer
works on x86_64 (with VMAP_STACK enabled as per default).
Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Signed-off-by: Ben Hutchings
---
drivers/net/usb/rtl8150.c | 34 +++---
1 file changed, 27
án Nicanor Pérez Meyer
Signed-off-by: Ben Hutchings
---
drivers/net/usb/pegasus.c | 29 +
1 file changed, 25 insertions(+), 4 deletions(-)
diff --git a/drivers/net/usb/pegasus.c b/drivers/net/usb/pegasus.c
index 24e803fe9a53..36674484c6fb 100644
--- a/drivers/net/usb
Allocating USB buffers on the stack is not portable, and no longer
works on x86_64 (with VMAP_STACK enabled as per default). This
series fixes all the instances I could find where USB networking
drivers do that.
Ben.
Ben Hutchings (4):
pegasus: Use heap buffers for all register access
to me. I haven't tested any version as
I don't know how to use TIPC.
Ben.
--
Ben Hutchings
A free society is one where it is safe to be unpopular. - Adlai
Stevenson
signature.asc
Description: This is a digitally signed message part
ks, a buffer overflow can occur if MTU is too short for
> > even tipc headers. As anyone can set device MTU in a user/net namespace,
> > this issue can be abused by a regular user.
> >
> > As agreed in the discussion on Ben Hutchings' original patch, we should
> >
above mentioned server is a 10g SFP+
> server with more than 4 Gbps traffic at certain times of day).
I didn't see any bug fixes relating to congestion control refcounts
after 4.7, so I'm guessing this bug is still present upstream.
Ben.
> I will test with a different congestion module (tcp_highspeed) to see if
> the issue is only htcp related or it is general issue of using congestion
> tcp modules.
>
> Panagiotis Malakoudis
--
Ben Hutchings
Time is nature's way of making sure that everything doesn't happen at
once.
signature.asc
Description: This is a digitally signed message part
On Fri, 2016-10-21 at 14:57 +, Jon Maloy wrote:
> > -Original Message-
> > > > From: Ben Hutchings [mailto:b...@decadent.org.uk]
> > Sent: Thursday, 20 October, 2016 12:40
> > > > To: Jon Maloy ; Ying Xue
> > > > > > Cc: netdev@v
you are in reality testing for whether we have an
> mtu < 84 bytes.
> You won't find any interfaces or protocols that come even close to this
> limitation, so to me this test is redundant.
But I can easily create such an interface:
$ unshare -n -U -r
# ip l set lo mtu 1
On Thu, 2016-10-20 at 17:30 +0800, Ying Xue wrote:
> On 10/19/2016 10:16 AM, Ben Hutchings wrote:
> > Qian Zhang (张谦) reported a potential socket buffer overflow in
> > tipc_msg_build(). The minimum fragment length needs to be checked
> > against the maximum packet size,
Qian Zhang (张谦) reported a potential socket buffer overflow in
tipc_msg_build(). The minimum fragment length needs to be checked
against the maximum packet size, which is based on the link MTU.
Reported-by: Qian Zhang (张谦)
Signed-off-by: Ben Hutchings
---
This is untested, but I think it fixes
You missed this wildcard, but I fixed it up. Applied and pushed,
thanks.
Ben.
--
Ben Hutchings
Anthony's Law of Force: Don't force it, get a larger hammer.
signature.asc
Description: This is a digitally signed message part
File: rtl_bt/rtl8821a_fw.bin
> +File: rtl_bt/rtl8822e_fw.bin
> +File: rtl_bt/rtl8822e_config.bin
[...]
Should the filenames begin with "rtl822b" or "rtl822e"?
Ben.
--
Ben Hutchings
All the simple programs have been written, and all the good names
taken.
signature.asc
Description: This is a digitally signed message part
ows it not
> initializing the structure I will not apply this patch because I know
> that it faithfully does.
On some versions and architectures. Can you guarantee that you will
notice when an exception appears?
Ben.
--
Ben Hutchings
The program is absolutely right; therefore, the
.
Unfortunately the C standard does not guarantee that padding bytes are
initialised (at least not for automatic storage).
[...]
> If we can not rely on such constructs, we have hundreds of similar
> patches to submit.
[...]
Many such patches have been applied and can be found with:
git log --author=kangji...@gmail.com
Ben.
--
Ben Hutchings
The program is absolutely right; therefore, the computer must be wrong.
signature.asc
Description: This is a digitally signed message part
On Sat, 2016-08-20 at 18:56 -0700, Alexander Duyck wrote:
> > On Sat, Aug 20, 2016 at 5:21 PM, Ben Hutchings wrote:
> >
> > On Fri, 2016-08-19 at 14:32 -0700, Alexander Duyck wrote:
> > >
> > > The i40e hardware has support for SCTP filtering via Rx NFC how
ng for SCTP using the previously
specified structure, but have you checked that that is the case?
Ben.
--
Ben Hutchings
It's easier to fight for one's principles than to live up to them.
signature.asc
Description: This is a digitally signed message part
return -EOPNOTSUPP;
> + }
[...]
> +static const struct ethtool_ops ena_ethtool_ops = {
> + .get_settings = ena_get_settings,
[...]
get_settings is now deprecated in favour of get_link_ksettings.
Ben.
Ben.
--
Ben Hutchings
For every action, there is an equal and opposite criticism. - Harrison
signature.asc
Description: This is a digitally signed message part
than that, actually put the check in the generic
> functions, because if the link is down, aka netif_running() returns
> false, link parameters cannot be reliably queried and they are invalid.
Either the hardware or the driver needs to remember:
- Is auto-negotiation enabled
- If so
On Fri, 2016-07-01 at 10:33 +0800, zhuyj wrote:
> I am interested in this, too.
You didn't say anything about your experience with Linux networking,
and I couldn't find many contributions from you. So you are welcome to
help with ethtool but I've selected John as the maintaine
On Thu, 2016-06-30 at 14:37 -0500, Jorge Alberto Garcia wrote:
> El 30/06/2016 02:32 p.m., "Ben Hutchings" escribió:
> >
> > On Thu, 2016-06-30 at 14:27 -0500, Jorge Alberto Garcia wrote:
> > > On Thu, Jun 30, 2016 at 1:15 PM, John W. Linville
> > > w
On Mon, 2016-06-27 at 09:51 -0400, John W. Linville wrote:
> On Sun, Jun 26, 2016 at 06:11:41PM +0200, Ben Hutchings wrote:
> > I've become steadily less enthusiastic and less responsive as a
> > maintainer over the past year or so. I no longer work on networking
> > re
On Thu, 2016-06-30 at 14:27 -0500, Jorge Alberto Garcia wrote:
> On Thu, Jun 30, 2016 at 1:15 PM, John W. Linville
> wrote:
> > On Mon, Jun 27, 2016 at 09:51:47AM -0400, John W. Linville wrote:
> > > On Sun, Jun 26, 2016 at 06:11:41PM +0200, Ben Hutchings wrote:
> > &g
On Mon, 2016-06-27 at 00:02 +0200, Ben Hutchings wrote:
> On Sun, 2016-06-26 at 09:40 -0700, Vidya Sagar Ravipati wrote:
> > On Sun, Jun 26, 2016 at 2:33 AM, Ben Hutchings wrote:
> [...]
> > > This looks very similar to sff8472_diags, only with the actual values
> > >
On Sun, 2016-06-26 at 09:40 -0700, Vidya Sagar Ravipati wrote:
> On Sun, Jun 26, 2016 at 2:33 AM, Ben Hutchings wrote:
[...]
> > This looks very similar to sff8472_diags, only with the actual values
> > separated from the arrays of thresholds.
> >
> > Can the structur
onventional sub-command syntax, i.e. no '-'/'--' prefix
- More consistent output formatting
Ben.
--
Ben Hutchings
compatible: Gracefully accepts erroneous data from any source
signature.asc
Description: This is a digitally signed message part
not available
Ben.
--
Ben Hutchings
compatible: Gracefully accepts erroneous data from any source
signature.asc
Description: This is a digitally signed message part
Signed-off-by: Ben Hutchings
---
ethtool.8.in | 3 ++-
ethtool.c| 2 ++
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/ethtool.8.in b/ethtool.8.in
index 9dc5e252a1dc..e08c9a714551 100644
--- a/ethtool.8.in
+++ b/ethtool.8.in
@@ -947,7 +947,8 @@ Scott Feldman,
Andi Kleen
has been a hard dependency for as back as git history
goes (2005, shortly after version 3).
Signed-off-by: Ben Hutchings
---
I spotted this while reviewing David Decotigny's patch to use netlink
sockets.
Ben.
configure.ac | 1 -
1 file changed, 1 deletion(-)
diff --git a/configure
rames_low },
> - { "rx-usecs-high", CMDL_S32, &coal_rx_usec_high_wanted,
> - &ecoal.rx_coalesce_usecs_high },
> - { "rx-frames-high", CMDL_S32, &coal_rx_frames_high_wanted,
> - &ecoal.rx_max_co
sff8636_channel_diags scd[MAX_CHANNEL_NUM];
> +};
[...]
> --- /dev/null
> +++ b/sff-common.c
[...]
> +double convert_mw_to_dbm(double mw)
> +{
> + return (10. * log10(mw / 1000.)) + 30.;
> +}
[...]
This is copied from sfpdiag.c, so you should make that file use it
rather than a duplicate definition.
Ben.
--
Ben Hutchings
compatible: Gracefully accepts erroneous data from any source
signature.asc
Description: This is a digitally signed message part
++---------
> 1 file changed, 95 insertions(+), 78 deletions(-)
>
--
Ben Hutchings
compatible: Gracefully accepts erroneous data from any source
signature.asc
Description: This is a digitally signed message part
return 1;
> }
> if (strings->len > 32) {
> @@ -3836,6 +3862,7 @@ static int do_sprivflags(struct cmd_context
> *ctx)
> cmdline = calloc(strings->len, sizeof(*cmdline));
> if (!cmdline) {
> perror("Cannot parse arguments");
> + free(strings);
> return 1;
> }
> for (i = 0; i < strings->len; i++) {
> @@ -3852,6 +3879,7 @@ static int do_sprivflags(struct cmd_context
> *ctx)
> flags.cmd = ETHTOOL_GPFLAGS;
> if (send_ioctl(ctx, &flags)) {
> perror("Cannot get private flags");
> + free(strings);
> return 1;
> }
>
> @@ -3859,9 +3887,11 @@ static int do_sprivflags(struct cmd_context
> *ctx)
> flags.data = (flags.data & ~seen_flags) | wanted_flags;
> if (send_ioctl(ctx, &flags)) {
> perror("Cannot set private flags");
> + free(strings);
> return 1;
> }
>
> + free(strings);
> return 0;
> }
>
--
Ben Hutchings
compatible: Gracefully accepts erroneous data from any source
signature.asc
Description: This is a digitally signed message part
#define MAX_ADDR_LEN 32
> @@ -4645,6 +4648,10 @@ opt_found:
>
> /* Open control socket. */
> ctx.fd = socket(AF_INET, SOCK_DGRAM, 0);
> +#ifdef HAVE_LINUX_NETLINK_H
> + if (ctx.fd < 0)
> + ctx.fd = socket(AF_NETLINK, SOCK_
t; commit 793cf87de9d1 ("Set cmd field in ETHTOOL_GLINKSETTINGS response to
> wrong nwords").
[...]
Applied, with some style changes. Thanks for your patience.
Ben.
--
Ben Hutchings
compatible: Gracefully accepts erroneous data from any source
signature.asc
Description: This is a digitally signed message part
just make the
documentation harder to read.
Signed-off-by: Ben Hutchings
---
ethtool.8.in | 2 +-
ethtool.c| 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/ethtool.8.in b/ethtool.8.in
index 36da10ed6c87..9dc5e252a1dc 100644
--- a/ethtool.8.in
+++ b/ethtool.8.in
@@ -54,7
The fixed_phy driver doesn't have to be built-in, and it's
important that of_mdio supports it even if it's a module.
Signed-off-by: Ben Hutchings
---
Re-sending with the proper subject prefix.
Ben.
--- a/drivers/of/of_mdio.c
+++ b/drivers/of/of_mdio.c
@@ -274,7 +274,7 @@ st
Dual MAC devices don't necessarily have both MACs wired up, so ignore
those that are disabled.
Signed-off-by: Ben Hutchings
---
--- a/drivers/net/ethernet/ti/cpsw.c
+++ b/drivers/net/ethernet/ti/cpsw.c
@@ -2023,7 +2023,7 @@ static int cpsw_probe_dt(struct cpsw_pri
if
The fixed_phy driver doesn't have to be built-in, and it's
important that of_mdio supports it even if it's a module.
Signed-off-by: Ben Hutchings
---
--- a/drivers/of/of_mdio.c
+++ b/drivers/of/of_mdio.c
@@ -274,7 +274,7 @@ struct phy_device *of_phy_attach(struct
}
EXPORT_SYMBO
na_store_small_copy_len);
>
> This is what many other drivers call (rx_)copybreak. Perhaps it's time
> to add it to ethtool as well?
[...]
There is the 'tunable' ethtool API for random parameters like
rx_copybreak. The ethtool utility doesn't su
On Tue, 2016-06-14 at 11:52 -0700, Shrikrishna Khare wrote:
> Signed-off-by: Keyong Sun
> Signed-off-by: Manoj Tammali
> Signed-off-by: Shrikrishna Khare
Reviewed-by: Ben Hutchings
> ---
> v1-v2: v1 patch used special values of rx-usecs to differentiate between
> coalesc
0, sizeof(struct ethtool_coalesce));
[...]
The ethtool core already clears the structure, and it sets the cmd
field properly. This memset() should be removed.
Otherwise I think this is fine.
Ben.
--
Ben Hutchings
We get into the habit
the eeprom request.
>
> Putting endless values for each and every eeprom type a device has is
> just rediculous.
>
> I'm not going to continue promoting this broken and unscalable scheme,
> we have to fix this.
I don't think there's nothing broken here. ethtool
be the size by repeated eeprom calls, increasing
> the buffer size each time as needed until success.
But really it should use ETHTOOL_GMODULEINFO first.
Ben.
--
Ben Hutchings
The program is absolutely right; therefore, the computer must be wrong.
signature.asc
Description: This is a di
ll EEPROM.
> I agree we can go and do everything via MTD; The reason we've tried using this
> API was mainly... because it was there. And thus we thought this is the RIGHT
> method for providing users the way of reading their flash.
[...]
I think tha
g MTD
instead. These can be enumerated (through /proc/mtd or sysfs) and they
can be read and written through block devices.
Ben.
--
Ben Hutchings
Everything should be made as simple as possible, but not simpler.
- Albert
Einstein
signature.asc
Description: This is a digitally signed message part
; + val = (u64)bgmac_read(bgmac, s->offset + 4);
Isn't this missing a << 32?
Does reading the high 32 bits latch the value of the low 32 bits? If
not, you need to read the high bits again after the low bits and retry
if they changed.
> + val |=
t_device *dev, void
> __user *useraddr)
> {
> - struct ethtool_pauseparam pauseparam = { ETHTOOL_GPAUSEPARAM
> };
> + struct ethtool_pauseparam pauseparam;
> +
> + memset(&pauseparam, 0, sizeof(pauseparam));
> + pauseparam.cmd = ETHTOOL_GPAUSEPARAM;
>
> if
t realise that.
> So, why is there no source in the tree, but just the link to it?
An oversight which we need to fix.
> Because, I would like to do basically the same
> for carl9170fw and just add a link to the carl9170fw repository and
> save everyone this source update "song and dan
ntainer.
Ben.
> I know we discussed last netconf that we should look at possibly a new tool
> to address the shortcomings of ethtool, but I was not aware we had
> abandoned maintaining the current ethtool already before any replacement
> tool has been developed.
--
Ben Hutchings
Time is nature's way of making sure that everything doesn't happen at
once.
signature.asc
Description: This is a digitally signed message part
1 - 100 of 253 matches
Mail list logo