<feed xmlns='http://www.w3.org/2005/Atom'>
<title>samba.git/lib/socket/interfaces.c, branch talloc-2.4.4</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.</subtitle>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/'/>
<entry>
<title>lib/socket: rearrange iface_comp() to use NUMERIC_CMP</title>
<updated>2024-04-23T01:33:29+00:00</updated>
<author>
<name>Douglas Bagnall</name>
<email>douglas.bagnall@catalyst.net.nz</email>
</author>
<published>2024-04-08T05:06:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=7ba6fcb93656e5e88e1d5bcd6002747aa64f0a3a'/>
<id>7ba6fcb93656e5e88e1d5bcd6002747aa64f0a3a</id>
<content type='text'>
We rearrange rather than just replacing the subtraction, because that
would call ntohl() more than necessary, and I think the flow is a bit
clearer this way.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=15625

Signed-off-by: Douglas Bagnall &lt;douglas.bagnall@catalyst.net.nz&gt;
Reviewed-by: Andrew Bartlett &lt;abartlet@samba.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We rearrange rather than just replacing the subtraction, because that
would call ntohl() more than necessary, and I think the flow is a bit
clearer this way.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=15625

Signed-off-by: Douglas Bagnall &lt;douglas.bagnall@catalyst.net.nz&gt;
Reviewed-by: Andrew Bartlett &lt;abartlet@samba.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>lib:socket: Add missing newlines to logging messages</title>
<updated>2023-08-08T04:39:37+00:00</updated>
<author>
<name>Joseph Sutton</name>
<email>josephsutton@catalyst.net.nz</email>
</author>
<published>2023-08-07T04:33:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=6ee008d2d9197059f2861a51cf2e7a2b05476d2c'/>
<id>6ee008d2d9197059f2861a51cf2e7a2b05476d2c</id>
<content type='text'>
Signed-off-by: Joseph Sutton &lt;josephsutton@catalyst.net.nz&gt;
Reviewed-by: Andrew Bartlett &lt;abartlet@samba.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Joseph Sutton &lt;josephsutton@catalyst.net.nz&gt;
Reviewed-by: Andrew Bartlett &lt;abartlet@samba.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>lib:socket: Fix code spelling</title>
<updated>2023-04-14T05:25:33+00:00</updated>
<author>
<name>Andreas Schneider</name>
<email>asn@samba.org</email>
</author>
<published>2023-04-13T10:54:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=c6e1a949156398952ba7ea3bd8a164409abe985a'/>
<id>c6e1a949156398952ba7ea3bd8a164409abe985a</id>
<content type='text'>
Signed-off-by: Andreas Schneider &lt;asn@samba.org&gt;
Reviewed-by: Joseph Sutton &lt;josephsutton@catalyst.net.nz&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Andreas Schneider &lt;asn@samba.org&gt;
Reviewed-by: Joseph Sutton &lt;josephsutton@catalyst.net.nz&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>lib/socket: autodetect RSS using ETHTOOL_GRXRINGS</title>
<updated>2020-05-07T14:44:40+00:00</updated>
<author>
<name>Stefan Metzmacher</name>
<email>metze@samba.org</email>
</author>
<published>2020-05-07T09:06:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=d39636acea4fda840b23646b021e24559681b0b0'/>
<id>d39636acea4fda840b23646b021e24559681b0b0</id>
<content type='text'>
This is also used as part of 'ethtool -n rdma14' and
'ethtool -x rdma14'.

;#&gt; ethtool -n rdma14
8 RX rings available
rxclass: Cannot get RX class rule count: Operation not supported
RX classification rule retrieval failed

;#&gt; ethtool -x rdma14
RX flow hash indirection table for rdma14 with 8 RX ring(s):
    0:      0     1     2     3     4     5     6     7
    8:      0     1     2     3     4     5     6     7
RSS hash key:
Operation not supported
RSS hash function:
    toeplitz: on
    xor: off
    crc32: off

Signed-off-by: Stefan Metzmacher &lt;metze@samba.org&gt;
Reviewed-by: Ralph Boehme &lt;slow@samba.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This is also used as part of 'ethtool -n rdma14' and
'ethtool -x rdma14'.

;#&gt; ethtool -n rdma14
8 RX rings available
rxclass: Cannot get RX class rule count: Operation not supported
RX classification rule retrieval failed

;#&gt; ethtool -x rdma14
RX flow hash indirection table for rdma14 with 8 RX ring(s):
    0:      0     1     2     3     4     5     6     7
    8:      0     1     2     3     4     5     6     7
RSS hash key:
Operation not supported
RSS hash function:
    toeplitz: on
    xor: off
    crc32: off

Signed-off-by: Stefan Metzmacher &lt;metze@samba.org&gt;
Reviewed-by: Ralph Boehme &lt;slow@samba.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>lib/socket: let query_iface_speed_from_name() initialize memory passed to syscalls</title>
<updated>2020-05-07T14:44:39+00:00</updated>
<author>
<name>Stefan Metzmacher</name>
<email>metze@samba.org</email>
</author>
<published>2020-05-07T09:06:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=4ccb58160936d13a06c74ed1c28c855564b50f22'/>
<id>4ccb58160936d13a06c74ed1c28c855564b50f22</id>
<content type='text'>
I'm not sure if struct initializers would take care of padding,
so I use ZERO_STRUCT().

Signed-off-by: Stefan Metzmacher &lt;metze@samba.org&gt;
Reviewed-by: Ralph Boehme &lt;slow@samba.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
I'm not sure if struct initializers would take care of padding,
so I use ZERO_STRUCT().

Signed-off-by: Stefan Metzmacher &lt;metze@samba.org&gt;
Reviewed-by: Ralph Boehme &lt;slow@samba.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>lib:socket: If returning early, set ifaces</title>
<updated>2018-10-27T22:35:34+00:00</updated>
<author>
<name>David Mulder</name>
<email>dmulder@suse.com</email>
</author>
<published>2018-10-24T16:55:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=5391e21dea3168691cee1e6ef6c5959e46d62d1e'/>
<id>5391e21dea3168691cee1e6ef6c5959e46d62d1e</id>
<content type='text'>
Prevents a segfault in load_interfaces() when total interfaces == 1.
Fixes regression caused by da68a1b2f417ec82ea4ed3e7a4d867cef8ca8f93.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13665

Signed-off-by: David Mulder &lt;dmulder@suse.com&gt;
Reviewed-by: Ralph Böhme &lt;slow@samba.org&gt;
Reviewed-by: Volker Lendecke &lt;vl@samba.org&gt;
Reviewed-by: Jeremy Allison &lt;jra@samba.org&gt;

Autobuild-User(master): Volker Lendecke &lt;vl@samba.org&gt;
Autobuild-Date(master): Sun Oct 28 00:35:35 CEST 2018 on sn-devel-144
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Prevents a segfault in load_interfaces() when total interfaces == 1.
Fixes regression caused by da68a1b2f417ec82ea4ed3e7a4d867cef8ca8f93.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13665

Signed-off-by: David Mulder &lt;dmulder@suse.com&gt;
Reviewed-by: Ralph Böhme &lt;slow@samba.org&gt;
Reviewed-by: Volker Lendecke &lt;vl@samba.org&gt;
Reviewed-by: Jeremy Allison &lt;jra@samba.org&gt;

Autobuild-User(master): Volker Lendecke &lt;vl@samba.org&gt;
Autobuild-Date(master): Sun Oct 28 00:35:35 CEST 2018 on sn-devel-144
</pre>
</div>
</content>
</entry>
<entry>
<title>lib:socket: Return early if we have only one interface</title>
<updated>2018-03-20T22:16:16+00:00</updated>
<author>
<name>Andreas Schneider</name>
<email>asn@samba.org</email>
</author>
<published>2017-12-07T14:54:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=da68a1b2f417ec82ea4ed3e7a4d867cef8ca8f93'/>
<id>da68a1b2f417ec82ea4ed3e7a4d867cef8ca8f93</id>
<content type='text'>
This fixes compilation with -Wstrict-overflow=2

Signed-off-by: Andreas Schneider &lt;asn@samba.org&gt;
Reviewed-by: Andrew Bartlett &lt;abartlet@samba.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This fixes compilation with -Wstrict-overflow=2

Signed-off-by: Andreas Schneider &lt;asn@samba.org&gt;
Reviewed-by: Andrew Bartlett &lt;abartlet@samba.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>libsocket: Make sure ifr.ifr_name is null-terminated</title>
<updated>2016-12-03T02:40:53+00:00</updated>
<author>
<name>Andreas Schneider</name>
<email>asn@samba.org</email>
</author>
<published>2016-06-22T09:26:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=383530c164719b1ab41004f6dba2743ebba222ae'/>
<id>383530c164719b1ab41004f6dba2743ebba222ae</id>
<content type='text'>
Found by Coverity

Signed-off-by: Andreas Schneider &lt;asn@samba.org&gt;
Reviewed-by: Jeremy Allison &lt;jra@samba.org&gt;

Autobuild-User(master): Jeremy Allison &lt;jra@samba.org&gt;
Autobuild-Date(master): Sat Dec  3 03:40:53 CET 2016 on sn-devel-144
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Found by Coverity

Signed-off-by: Andreas Schneider &lt;asn@samba.org&gt;
Reviewed-by: Jeremy Allison &lt;jra@samba.org&gt;

Autobuild-User(master): Jeremy Allison &lt;jra@samba.org&gt;
Autobuild-Date(master): Sat Dec  3 03:40:53 CET 2016 on sn-devel-144
</pre>
</div>
</content>
</entry>
<entry>
<title>lib/socket/interfaces: Fix some uninitialied bytes.</title>
<updated>2016-03-12T05:24:24+00:00</updated>
<author>
<name>Günther Deschner</name>
<email>gd@samba.org</email>
</author>
<published>2016-03-02T17:32:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=2e2f81134c86ef3146781d62d9f561f496b74ee2'/>
<id>2e2f81134c86ef3146781d62d9f561f496b74ee2</id>
<content type='text'>
Valgrind reports the following:

==26599== Syscall param ioctl(SIOCETHTOOL) points to uninitialised byte(s)
==26599==    at 0x7014707: ioctl (in /usr/lib64/libc-2.22.so)
==26599==    by 0x79D1585: query_iface_speed_from_name (interfaces.c:152)
==26599==    by 0x79D1BBA: _get_interfaces (interfaces.c:277)
==26599==    by 0x79D1E80: get_interfaces (interfaces.c:368)
==26599==    by 0x508A7E3: load_interfaces (interface.c:612)
==26599==    by 0x150B30: main (net.c:963)
==26599==  Address 0xffefff0d8 is on thread 1's stack
==26599==  in frame #1, created by query_iface_speed_from_name
(interfaces.c:130)
==26599==
==26599== Syscall param ioctl(SIOCETHTOOL) points to uninitialised byte(s)
==26599==    at 0x7014707: ioctl (in /usr/lib64/libc-2.22.so)
==26599==    by 0x79D15CC: query_iface_speed_from_name (interfaces.c:164)
==26599==    by 0x79D1BBA: _get_interfaces (interfaces.c:277)
==26599==    by 0x79D1E80: get_interfaces (interfaces.c:368)
==26599==    by 0x508A7E3: load_interfaces (interface.c:612)
==26599==    by 0x150B30: main (net.c:963)
==26599==  Address 0xffefff0d8 is on thread 1's stack
==26599==  in frame #1, created by query_iface_speed_from_name
(interfaces.c:130)

Guenther

Signed-off-by: Guenther Deschner &lt;gd@samba.org&gt;
Reviewed-by: Jeremy Allison &lt;jra@samba.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Valgrind reports the following:

==26599== Syscall param ioctl(SIOCETHTOOL) points to uninitialised byte(s)
==26599==    at 0x7014707: ioctl (in /usr/lib64/libc-2.22.so)
==26599==    by 0x79D1585: query_iface_speed_from_name (interfaces.c:152)
==26599==    by 0x79D1BBA: _get_interfaces (interfaces.c:277)
==26599==    by 0x79D1E80: get_interfaces (interfaces.c:368)
==26599==    by 0x508A7E3: load_interfaces (interface.c:612)
==26599==    by 0x150B30: main (net.c:963)
==26599==  Address 0xffefff0d8 is on thread 1's stack
==26599==  in frame #1, created by query_iface_speed_from_name
(interfaces.c:130)
==26599==
==26599== Syscall param ioctl(SIOCETHTOOL) points to uninitialised byte(s)
==26599==    at 0x7014707: ioctl (in /usr/lib64/libc-2.22.so)
==26599==    by 0x79D15CC: query_iface_speed_from_name (interfaces.c:164)
==26599==    by 0x79D1BBA: _get_interfaces (interfaces.c:277)
==26599==    by 0x79D1E80: get_interfaces (interfaces.c:368)
==26599==    by 0x508A7E3: load_interfaces (interface.c:612)
==26599==    by 0x150B30: main (net.c:963)
==26599==  Address 0xffefff0d8 is on thread 1's stack
==26599==  in frame #1, created by query_iface_speed_from_name
(interfaces.c:130)

Guenther

Signed-off-by: Guenther Deschner &lt;gd@samba.org&gt;
Reviewed-by: Jeremy Allison &lt;jra@samba.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>lib/socket: Fix improper use of default interface speed</title>
<updated>2016-02-13T15:22:22+00:00</updated>
<author>
<name>Anoop C S</name>
<email>anoopcs@redhat.com</email>
</author>
<published>2016-02-11T09:25:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=9fb98e3e056f059e2a5fcdd54a6a0d60ecdb01b7'/>
<id>9fb98e3e056f059e2a5fcdd54a6a0d60ecdb01b7</id>
<content type='text'>
_get_interfaces() function from interfaces.c uses if_speed
variable to store interface speed and is initialized with a
default value at start. But if_speed populated via one
iteration for a specific IP address will be treated as the
default value for next iteration which is wrong. Therefore
change is to move the initialization cum declaration of
if_speed inside iteration of IP addresses loop.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11734

Signed-off-by: Anoop C S &lt;anoopcs@redhat.com&gt;
Reviewed-by: Michael Adam &lt;obnox@samba.org&gt;
Reviewed-by: Stefan Metzmacher &lt;metze@samba.org&gt;

Autobuild-User(master): Michael Adam &lt;obnox@samba.org&gt;
Autobuild-Date(master): Sat Feb 13 16:22:22 CET 2016 on sn-devel-144
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
_get_interfaces() function from interfaces.c uses if_speed
variable to store interface speed and is initialized with a
default value at start. But if_speed populated via one
iteration for a specific IP address will be treated as the
default value for next iteration which is wrong. Therefore
change is to move the initialization cum declaration of
if_speed inside iteration of IP addresses loop.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11734

Signed-off-by: Anoop C S &lt;anoopcs@redhat.com&gt;
Reviewed-by: Michael Adam &lt;obnox@samba.org&gt;
Reviewed-by: Stefan Metzmacher &lt;metze@samba.org&gt;

Autobuild-User(master): Michael Adam &lt;obnox@samba.org&gt;
Autobuild-Date(master): Sat Feb 13 16:22:22 CET 2016 on sn-devel-144
</pre>
</div>
</content>
</entry>
</feed>
