summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* platform: fix wrapper nm_platform_addr_flags2str() for rtnl_addr_flags2str()th/nm_platform_addr_flags2strThomas Haller2014-04-074-22/+136
| | | | | | | | | | The compatibily wrapper for rtnl_addr_flags2str() did not behave identical because libnl adds a trailing ',' if it encounters unknown attributes. Try to fix that and add test cases. Signed-off-by: Thomas Haller <thaller@redhat.com>
* examples: fix qt demo to work without STL supportThomas Haller2014-04-041-2/+2
| | | | | | | | | | | | | | | | The function toStdString() is only available when QT was compiled with STL support. The configure script does not check STL support and might build the QT examples even if toStdString() is not available. Fix this, by not using the function. This fixes the previous commit f73e3669b3bb9b3547173896dcea8e2eb17d30ec that I pushed accidentally. https://bugzilla.gnome.org/show_bug.cgi?id=727608 Signed-off-by: Thomas Haller <thaller@redhat.com>
* platform: workaround older kernels that don't accept extended address flags ↵Thomas Haller2014-04-041-1/+12
| | | | | | | | | | | | | | | | | | | | | via netlink Extended address flags are represented by the additional netlink attribute IFA_FLAGS. Older kernels don't know this flag and refuse the messages RTM_NEWADDR and RTMDEL_ADDR when it contains unknown attributes. See net/core/rtnetlink.c, rtnetlink_rcv_msg(). This was fixed by kernel commit 661d2967b3f1b34eeaa7e212e7b9bbe8ee072b59. libnl was fixed in commit 5206c050504f8676a24854519b9c351470fb7cc6 only to send the additional netlink attribute, when there are actually flags that make this necessary. This commit changes nm-platform to strip the flags to &= 0xFF, if we detect that the kernel does not understand extended address flags. https://bugzilla.redhat.com/show_bug.cgi?id=1063885 Signed-off-by: Thomas Haller <thaller@redhat.com>
* examples: fix qt demo to work without STL supportThomas Haller2014-04-041-2/+2
| | | | | | | | | | | | | The function toStdString() is only available when QT was compiled with STL support. The configure script does not check STL support and might build the QT examples even if toStdString() is not available. Fix this, by not using the function. https://bugzilla.gnome.org/show_bug.cgi?id=727608 Signed-off-by: Thomas Haller <thaller@redhat.com>
* fix typos in documentation and messagesYuri Chornoivan2014-04-033-5/+5
| | | | | | https://bugzilla.gnome.org/show_bug.cgi?id=727031 Signed-off-by: Thomas Haller <thaller@redhat.com>
* core: add macro STRLENThomas Haller2014-04-031-0/+3
| | | | | | | | Returns the length of a string at compile time. Contrary to strlen(), which is a run time expression -- even if the compler might be able to optimize strlen() for string constants. Signed-off-by: Thomas Haller <thaller@redhat.com>
* cli: fix setting DCB application priority (rh #1080510)Dan Williams2014-04-021-4/+4
| | | | | Priority was originally a 'guint' but then got changed to 'gint' and apparently we forgot to fix one place up.
* merge: DCB-related workarounds for lldpad and driver bugs (rh #799241) (rh ↵Dan Williams2014-04-024-40/+330
|\ | | | | | | | | | | | | | | | | | | #1081991) lldpad 0.9.46 and earlier appear to be very sensitive to carrier, and if the interface has no carrier will refuse to do anything with it, reporting that "Device not found, link down or DCB not enabled". So while setting up and tearing down DCB configuration, we must wait for the carrier at various points before proceeding, to ensure that the operations are successful.
| * dcb: wait for carrier down/up after disabling FCoEDan Williams2014-04-021-0/+32
| |
| * dcb: separate DCB enable/disable and wait for carrier changes (rh #799241) ↵Dan Williams2014-04-024-42/+300
|/ | | | | | | | | | | | | | | | | | | | | (rh #1081991) Non-git-master versions of lldpad refuse to touch a device that doesn't have a carrier. And when enabling/disabling DCB, the kernel driver will reconfigure itself and may turn carrier off for a few seconds. So we must ensure that before enabling/disabling DCB, the carrier is already on. Next we must ensure that *after* enabling/disabling DCB, the carrier is back on before doing further DCB setup. There's a race condition between enabling/disabling DCB and receiving the carrier event in NetworkManager that has to be handled carefully. Because the carrier may not yet be down after the dcbtool call to enable/disable DCB returns, we need to wait for a couple seconds for the carrier to go down, and then again for it to come back up. Otherwise we might see the still-on carrier, proceed with DCB setup, and the carrier finally goes down halfway through the setup, which will fail the operations with "DCB not enabled, link down, or DCB not supported" errors from lldpad.
* core: fix bug with ignore-carrier and master/slave devices (rh #1083521)Dan Williams2014-04-021-5/+3
| | | | | | Even ignore-carrier devices need to be aware of carrier-up events so they can continue DHCP when the link comes up. They just ignore all carrier-down events.
* build: add -Wformat-security to the default warning flagsDan Winship2014-04-021-1/+1
|
* dcb: fix -Wformat-security bugsDan Winship2014-04-021-2/+2
|
* ifcfg-rh: fix compile error with HAVE_SELINUXThomas Haller2014-04-011-1/+1
| | | | | | Related: https://bugzilla.redhat.com/show_bug.cgi?id=1070829 Signed-off-by: Thomas Haller <thaller@redhat.com>
* ifcfg-rh: fix bugs in the new alias code (rh #1067170)Dan Winship2014-04-012-8/+11
| | | | | | | | | Fix a bug when reading an invalid alias file, where the code meant to skip the rest of the loop iteration, but failed. Also fix a memory leak and remove an unused variable. Bugs noticed by coverity.
* trivial: add a (void) annotation for coverityDan Winship2014-04-011-1/+1
|
* libnm-util: fix leaks in test-generalDan Winship2014-04-011-0/+3
|
* po: fix "MB/s" -> "Mbit/s"Jiří Klimeš2014-04-0142-79/+79
|
* man: use correct Mbit/s for maximum bitrate in nmcli-examplesJiří Klimeš2014-04-011-12/+12
|
* examples: use correct Mbit/s for bitratesJiří Klimeš2014-04-011-2/+2
|
* nmcli: use correct Mbit/s units for maximal bitrate (rh #1080474)Jiří Klimeš2014-04-011-1/+1
| | | | https://bugzilla.redhat.com/show_bug.cgi?id=1080474
* trivial: make clear the maximum bitrate is in kbit/sJiří Klimeš2014-04-013-7/+7
|
* core: ensure activation does not disconnect private connectionsDan Williams2014-03-311-0/+25
| | | | | | | | | If two users had the ability to control networking, and user1 started a private connection which user2 cannot see, user2 could start their own connection and disconnect user1's connection. This is not consistent with device disconnection. A user who cannot see a connection should not be able to start/stop it, even if they are allowed to control networking in general.
* nmcli: fix an error when showing progress of activation in editorJiří Klimeš2014-03-311-6/+13
| | | | (process:7213): CRITICAL **: nm_active_connectiuon_get_state: assertion `NM_IS_ACTIVE_CONNECTION (connection)' failed
* ifcfg-rh: put \n after hostname when writing it to /etc/hostnameJiří Klimeš2014-03-311-1/+5
|
* core: build with SELinux; don't break /etc/hostname context (rh #1070829)Jiří Klimeš2014-03-312-2/+47
| | | | https://bugzilla.redhat.com/show_bug.cgi?id=1070829
* Merge fixes for nm-online (rh #rh1054364)Jiří Klimeš2014-03-314-13/+55
|\ | | | | | | https://bugzilla.redhat.com/show_bug.cgi?id=1054364
| * nm-online: fix considering the --quiet optionThomas Haller2014-03-311-2/+3
| | | | | | | | Signed-off-by: Thomas Haller <thaller@redhat.com>
| * trivial: correct nm-online's '--exit' option descriptionJiří Klimeš2014-03-311-1/+1
| |
| * systemd: update NetworkManager-wait-online.service to wait for startupJiří Klimeš2014-03-312-2/+2
| |
| * nm-online: fix nm-online to report online status correctly (rh #1054364)Jiří Klimeš2014-03-312-8/+49
|/ | | | | | | | | | | | | | | | | | This fixes a behaviour change made by 44ac1020daccfeeb1dc88566adda6e5d8bd87aea. That commit make nm-online to wait for NM finishing startup instead of waiting for a real connection. So for NetworkManager fully initialized, but disconnected nm-online would return 0. $ nmcli -f RUNNING,STATE,STARTUP,CONNECTIVITY gen status RUNNING STATE STARTUP CONNECTIVITY running disconnected started none Revert back to the original behaviour of waiting for a connection. And introduce a new option '--wait-for-startup' waiting for NetworkManager finishing its startup, which is useful in some cases, like NetworkManager-wait-online.service. https://bugzilla.redhat.com/show_bug.cgi?id=1054364
* po: updated Ukranian translation (bgo #727033)Yuri Chornoivan2014-03-281-1203/+1481
|
* core: update NMManager:devices before emitting notify::devices (rh #1078720)Dan Winship2014-03-271-2/+2
| | | | | | | | NMClient's "devices" property was getting out of sync because the daemon was emitting "notify" before actually changing the property value. This resulted in problems with re-activating virtual devices that had previously been deactivated in gnome-control-center and anaconda. (And probably gnome-shell and nm-applet?)
* platform: fix handling of labelsDan Winship2014-03-261-1/+2
| | | | | If an address has a label without a ':' in it (eg, its label is just $DEVICE, not $DEVICE:$NUM), then ignore it.
* devices: if a generated connection doesn't verify, log whyDan Winship2014-03-261-1/+8
|
* ifcfg-rh: add support for ifcfg alias files (rh #1067170)Dan Winship2014-03-2630-78/+1298
|\
| * keyfile: ignore ipv4.address-labelsDan Winship2014-03-261-0/+14
| | | | | | | | For now they are only supported by ifcfg-rh
| * ifcfg-rh: add support for reading and writing ifcfg alias filesDan Winship2014-03-2614-50/+841
| |
| * core: handle IPv4 address labelsDan Winship2014-03-261-2/+8
| | | | | | | | | | Handle address labels when applying or capturing an NMSettingIP4Config.
| * platform: support address labels for IPv4 addressesDan Winship2014-03-267-19/+54
| |
| * libnm-util: add (private API) support for address labels to NMSettingIP4ConfigDan Winship2014-03-265-7/+283
| |
| * libnm-util: add nm-util-private.h header with nm_util_get_private()Dan Winship2014-03-264-0/+98
|/
* dcb: fix testcases for disabling DCB with short-format commandDan Williams2014-03-261-5/+5
| | | | Late-fixup for review comments and I didn't run 'make check'. Bad me.
* wifi: fixup for "wifi: support locking connections to a band (5GHz or 2GHz) ↵Dan Williams2014-03-261-0/+1
| | | | | | (bgo #627571)" The new freq_list option must pass configuration verification.
* dcb: workarounds for lldpad/drivers and some bug fixes (rh #799241)Dan Williams2014-03-252-48/+97
|\
| * dcb: turn off all DCB features when disabling DCBDan Williams2014-03-252-3/+27
| | | | | | | | Don't just disable DCB, but turn off the features too.
| * dcb: ignore fcoeadm success errors like "Connection already created"Dan Williams2014-03-251-5/+13
| | | | | | | | | | | | | | | | | | | | | | | | $ /usr/sbin/fcoeadm -m fabric -c enp3s0f0 fcoeadm: Connection already created on interface enp3s0f0 Try 'fcoeadm --help' for more information. $ echo $? 3 $ Also now log error output of failed commands instead of only when debug logging is enabled.
| * dcb: clean up FCoE tooDan Williams2014-03-251-1/+9
| |
| * dcb: fix memory leakDan Williams2014-03-251-0/+1
| |
| * dcb: set all Priority Group options at the same time (rh #799241)Dan Williams2014-03-252-39/+47
|/ | | | | | | | | | | | | | | | First, lldpad doesn't support disabling priority groups (e:0) without specifying a complete priority group config (which wouldn't be used anyway, since you're turning it off!). While this bug is being fixed upstream, we'll just ignore errors turning off PG, since if you're using DCB on an interface, you probably want to use it all the time. Second, lldpad really wants all PG options on the same configuration line, not split apart, because it validates the complete package of options before applying them, regardless of whether or not they are given in the same command. Since NM was just emitting all the options in separate dcbtool invocations anyway, just combine them all into a single invocation.