<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/NetworkManager.git/src/platform/nm-netlink.c, branch lr/python3</title>
<subtitle>gitlab.freedesktop.org: NetworkManager/NetworkManager.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/'/>
<entry>
<title>platform: move genl_ctrl_resolve to nm-netlink.c</title>
<updated>2018-03-30T20:09:04+00:00</updated>
<author>
<name>Javier Arteaga</name>
<email>jarteaga@jbeta.is</email>
</author>
<published>2018-03-29T20:00:28+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=56e79a4e07e70f7786aa5bcfb6d2aedf082c1cd6'/>
<id>56e79a4e07e70f7786aa5bcfb6d2aedf082c1cd6</id>
<content type='text'>
Move genl_ctrl_resolve out of the wifi code so it can be reused by other
interfaces based on genetlink.

https://mail.gnome.org/archives/networkmanager-list/2018-March/msg00044.html
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Move genl_ctrl_resolve out of the wifi code so it can be reused by other
interfaces based on genetlink.

https://mail.gnome.org/archives/networkmanager-list/2018-March/msg00044.html
</pre>
</div>
</content>
</entry>
<entry>
<title>platform: print error message from netlink extended ack</title>
<updated>2018-03-09T16:52:43+00:00</updated>
<author>
<name>Beniamino Galvani</name>
<email>bgalvani@redhat.com</email>
</author>
<published>2018-03-08T16:01:35+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=b107e121b0f6d8a30c3dba7aa0ac04036934eb00'/>
<id>b107e121b0f6d8a30c3dba7aa0ac04036934eb00</id>
<content type='text'>
From v4.12 the kernel appends some attributes to netlink acks
containing a textual description of the error and other fields (see
commit [1]). Parse those attributes and print the error message.

Examples:

platform-linux: netlink: recvmsg: error message from kernel: Network is unreachable (101) "Nexthop has invalid gateway" for request 12

platform-linux: netlink: recvmsg: error message from kernel: Invalid argument (22) "Local address cannot be multicast" for request 21

[1] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=2d4bc93368f5a0ddb57c8c885cdad9c9b7a10ed5
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
From v4.12 the kernel appends some attributes to netlink acks
containing a textual description of the error and other fields (see
commit [1]). Parse those attributes and print the error message.

Examples:

platform-linux: netlink: recvmsg: error message from kernel: Network is unreachable (101) "Nexthop has invalid gateway" for request 12

platform-linux: netlink: recvmsg: error message from kernel: Invalid argument (22) "Local address cannot be multicast" for request 21

[1] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=2d4bc93368f5a0ddb57c8c885cdad9c9b7a10ed5
</pre>
</div>
</content>
</entry>
<entry>
<title>platform: cleanup error handling in event_handler_recvmsgs()</title>
<updated>2018-02-21T11:08:46+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2018-02-17T15:33:00+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=b3633a282d9b4a22cd605914219cf1d423bfcfcf'/>
<id>b3633a282d9b4a22cd605914219cf1d423bfcfcf</id>
<content type='text'>
Now that we cleaned up nl_recv(), we have full control over which error
variables are returned when. We no longer need to check "errno"
directly, and we no longer need the NLE_USER_* workaround.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Now that we cleaned up nl_recv(), we have full control over which error
variables are returned when. We no longer need to check "errno"
directly, and we no longer need the NLE_USER_* workaround.
</pre>
</div>
</content>
</entry>
<entry>
<title>netlink: various cleanups and use cleanup attribute</title>
<updated>2018-02-21T11:08:46+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2018-02-17T15:04:43+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=ba25221236f545eaee380e2425d213c480340f12'/>
<id>ba25221236f545eaee380e2425d213c480340f12</id>
<content type='text'>
- adjust some coding style (space after function name).
- ensure to use g_free(), as we no longer use malloc
  but the g_malloc aliases. Nowadays, glib's malloc
  is identical to malloc from the standard library and
  so this is no issue in practice. Still it's bad
  style to mix g_malloc() with free().
- use cleanup attribute for memory handling.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- adjust some coding style (space after function name).
- ensure to use g_free(), as we no longer use malloc
  but the g_malloc aliases. Nowadays, glib's malloc
  is identical to malloc from the standard library and
  so this is no issue in practice. Still it's bad
  style to mix g_malloc() with free().
- use cleanup attribute for memory handling.
</pre>
</div>
</content>
</entry>
<entry>
<title>netlink: use slice allocator for "struct nl_msg"</title>
<updated>2018-02-21T11:08:46+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2018-02-16T16:48:20+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=5376aa2db70e20a195da17cb1ffa5ad59c76868a'/>
<id>5376aa2db70e20a195da17cb1ffa5ad59c76868a</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>netlink: use glib allocator functions for nlmsg_alloc*()</title>
<updated>2018-02-21T11:08:46+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2018-02-16T16:43:26+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=ff7f8b3a79243b62830137853c985900277adb4a'/>
<id>ff7f8b3a79243b62830137853c985900277adb4a</id>
<content type='text'>
Glib is not out of memory safe, meaning it always aborts the program
when an allocation fails. It is not possible to meaningfully handle
out of memory when using glib.

Replace all allocation functions for netlink message with their glib
counter part and remove the NULL checks.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Glib is not out of memory safe, meaning it always aborts the program
when an allocation fails. It is not possible to meaningfully handle
out of memory when using glib.

Replace all allocation functions for netlink message with their glib
counter part and remove the NULL checks.
</pre>
</div>
</content>
</entry>
<entry>
<title>netlink: simplify netlink callback handling</title>
<updated>2018-02-21T11:08:46+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2018-02-16T16:05:32+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=a7bda2ed12b958fd605e78a2512aa7246046983a'/>
<id>a7bda2ed12b958fd605e78a2512aa7246046983a</id>
<content type='text'>
With libnl3, each socket has it's own callback structure.
One would often take that callback structure, clone it, modify it
and invoke a receive operation with it.

We don't need this complexity. We got rid of all default handlers,
hence, by default all callbacks are unset.

The only callbacks that are set, are those that we specify immediately
before invoking the receive operation. Just pass the callback structure
at that point.

Also, no more ref-counting, and cloning of the callback structure. It is
so simple, just stack allocate one if you need it.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
With libnl3, each socket has it's own callback structure.
One would often take that callback structure, clone it, modify it
and invoke a receive operation with it.

We don't need this complexity. We got rid of all default handlers,
hence, by default all callbacks are unset.

The only callbacks that are set, are those that we specify immediately
before invoking the receive operation. Just pass the callback structure
at that point.

Also, no more ref-counting, and cloning of the callback structure. It is
so simple, just stack allocate one if you need it.
</pre>
</div>
</content>
</entry>
<entry>
<title>netlink: drop redundant nl_recvmsgs_report() function</title>
<updated>2018-02-21T11:08:46+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2018-02-16T16:06:35+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=4da2a19a873d6cc51720d54c6f4183783ad4a56d'/>
<id>4da2a19a873d6cc51720d54c6f4183783ad4a56d</id>
<content type='text'>
The only difference between nl_recvmsgs_report() and nl_recvmsgs() is
the return value on success. libnl3 couldn't change that for backward
compatibility reasons. We can merge them.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The only difference between nl_recvmsgs_report() and nl_recvmsgs() is
the return value on success. libnl3 couldn't change that for backward
compatibility reasons. We can merge them.
</pre>
</div>
</content>
</entry>
<entry>
<title>netlink: drop unused callback types</title>
<updated>2018-02-21T11:08:46+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2018-02-16T14:59:40+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=03420e6a5c67df7a04ad2a39e72677ec190b1061'/>
<id>03420e6a5c67df7a04ad2a39e72677ec190b1061</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>netlink: remove unused callback hooks</title>
<updated>2018-02-21T11:08:46+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2018-02-16T14:51:11+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=356332a8406dd675b05f97b41ca6d795c7f304bb'/>
<id>356332a8406dd675b05f97b41ca6d795c7f304bb</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
</feed>
