Commit Graph

10349 Commits

Author SHA1 Message Date
Zbigniew Jedrzejewski-Szmek
f8e5fbd9c8 Remove unnecessary casts in printfs
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-05-15 19:34:56 -04:00
Kay Sievers
db992ba3a7 udev: do not skip the execution of RUN when renaming a network device fails
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-05-15 17:25:25 -04:00
Anthony G. Basile
47ef6b2c66 src/libudev/missing.h: clean up and fix build on uclibc and musl
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-05-13 10:53:21 -04:00
Kay Sievers
a19b50448a hwdb: update
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-05-10 18:38:51 -04:00
Anthony G. Basile
8292d01912 src/scsi_id/scsi_id.c: Add _GNU_SOURCE for struct file_handle
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-05-01 12:14:48 -04:00
Anthony G. Basile
9916d5e79c src/libudev/path-util.c: don't use IN_SET() macro
We do not import this macro which is unnecessarily complex
for this one case.

Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-05-01 09:49:01 -04:00
Zbigniew Jędrzejewski-Szmek
8e22a81141 udev: warn when name_to_handle_at is not implemented
We have a bunch of reports from people who have a custom kernel and
are confused why udev is not running. Issue a warning on
error. Barring an error in the code, the only error that is possible
is ENOSYS.

https://bugzilla.redhat.com/show_bug.cgi?id=1072966
2014-04-26 14:10:21 -04:00
Lennart Poettering
56127c00c3 util: make sure all our name_to_handle_at() code makes use of file_handle_union
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-04-26 14:09:19 -04:00
Dave Reisner
c59a37701b implement a union to pad out file_handle
Cases where name_to_handle_at is used allocated the full struct to be
MAX_HANDLE_SZ, and assigned this size to handle_bytes. This is wrong
since handle_bytes should describe the length of the flexible array
member and not the whole struct.

Define a union type which includes sufficient padding to allow
assignment of MAX_HANDLE_SZ to be correct.

Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-04-26 14:06:06 -04:00
Robert Milasan
48255c443b udev: increase the size of RESULT buffer
Under some conditions, in udev_rules_apply_to_event the fact that
result is 1024 bytes, creates problems if the output of the running
command/app is bigger then 1024 bytes.

Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-04-24 16:12:18 -04:00
Kay Sievers
2ac0b74a96 udev: serialize/synchronize block device event handling with file locks
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-04-24 16:08:14 -04:00
Anthony G. Basile
01ae6f2a16 src/libudev: whitespace cleanup
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-04-24 16:05:18 -04:00
Anthony G. Basile
da46611254 src/udev: code cleanup
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-04-24 16:02:16 -04:00
Kay Sievers
2500dbc810 udev: remove seqnum API and all assumptions about seqnums
The way the kernel namespaces have been implemented breaks assumptions
udev made regarding uevent sequence numbers. Creating devices in a
namespace "steals" uevents and its sequence numbers from the host. It
confuses the "udevadmin settle" logic, which might block until util a
timeout is reached, even when no uevent is pending.

Remove any assumptions about sequence numbers and deprecate libudev's
API exposing these numbers; none of that can reliably be used anymore
when namespaces are involved.

Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-04-24 15:40:08 -04:00
Marcel Holtmann
dbc5e32fae hwdb: Update database of Bluetooth company identifiers
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-04-12 19:12:34 -04:00
Tom Gundersen
bd255c361d udev: net_id - use constants rather than magic numbers
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-04-07 08:35:31 -04:00
Anthony G. Basile
4b76ac0bff Revisit issue #87: fails to build on linux headers 3.13
We switch to defining _GNU_SOURCE as we do for cdrom_id.c
for a more consistant approach to this issue.

Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-04-05 16:32:30 -04:00
Eric Le Bihan
c4c2658040 libudev: Fix redefinition of usec_t and nsec_t.
The type definitions usec_t and nsec_t where defined twice: in
path-util.h and util.h.

time-util.h and time-util.c now gather the time-related functions and
definitions (as in upstream systemd).

Signed-off-by: Eric Le Bihan <eric.le.bihan.dev@free.fr>
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-04-04 13:36:54 -04:00
Anthony G. Basile
a1a5424a62 configure.ac: bring version numbers in line with upstream
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-04-03 13:31:29 -04:00
Kay Sievers
40c72b0478 udev: do not export "static node" tags for non-existing devices
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-04-03 08:55:58 -04:00
Tom Gundersen
5aafc733e7 udev: persistent naming - we cannot use virtio numbers as they are not stable
This reverts commit 8741f2defa: 'Add virtio-blk support to path_id' and
commit e3d563346c4237af23335cc6904e0662efdf62ad: 'udev: net_id - handle virtio buses'.

Distros may want to take note of this, as it changes behavior.

Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-03-28 11:44:54 -04:00
Kay Sievers
0d6a3aec20 udev: update net_id comments
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-03-28 11:43:15 -04:00
Anthony G. Basile
75e0b7ce10 Update hwdb
This is upstream commits

    f89b42ec0fd51feab5566d6bdbacee101023c037

    15f392394e75ffb7f318920008fd1bbe4e82b488

by Marcel Holtmann <marcel@holtmann.org> and Scott Thrasher <scott.thrasher@gmail.com>

Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-03-28 11:40:34 -04:00
Anthony G. Basile
6330a66ad2 configure.ac: bump to 1.5.3
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-03-22 18:44:40 -04:00
Kay Sievers
0114457e2f hwdb: update 2014-03-22 18:21:20 -04:00
Anthony G. Basile
974354dee5 Revisit issue #87: fails to build on linux headers 3.13
Dropping <fcntl.h> in favor of <linux/fcntl.h> is incorrect.  Yet
uClibc needs O_CLOEXEC from <linux/fcntl.h>.  So we re-introduce
<fcntl.h> and include <linux/fcntl.h> only on uClibc systems to
avoid redefinitions.

Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-03-22 18:07:36 -04:00
blueness
ac73951d24 Merge pull request #91 from lhb-jr/fix_discardconst_warn
src/udev/udev-builtin-kmod.c: fix discardconst warn

Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-03-22 16:52:55 -04:00
blueness
fbfcfb49a6 Merge pull request #90 from lhb-jr/fix_nocheckreturn
Fixed gcc warnings that call returns not checked

Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-03-22 16:51:07 -04:00
blueness
12c87cef17 Merge pull request #88 from lhb-jr/check_for_docbook
configure.ac: find docbook catalog

Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-03-22 16:50:11 -04:00
lhb-jr
a45adc4f91 completed fix to 'discard const' warning
modified:   src/udev/udev-builtin-kmod.c
2014-03-21 12:19:04 -04:00
lhb-jr
123cccd833 workaround 'discards const' warning during compile
modified:   src/udev/udev-builtin-kmod.c

Temporary copies of the arguments to the 'execv' call are made so that gcc doesn't give,
possibly confusing warning about 'discarding const' during compilation.
2014-03-21 12:04:32 -04:00
lhb-jr
728baddb47 fixed gcc warnings that call returns not checked
modified:   src/collect/collect.c
modified:   src/udev/udev-node.c
modified:   src/udev/udevadm-settle.c
modified:   src/udev/udevd.c
2014-03-21 11:55:36 -04:00
lhb-jr
8a5de44bb8 modified: configure.ac
modified:   man/Makefile.am
Added checking for DocBook in configure
2014-03-20 20:51:06 -04:00
Anthony G. Basile
c0acbd0656 UPSTREAM.notes: updated
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-03-17 12:13:50 -04:00
Martin Pitt
2d98bf7569 input_id: Recognize buttonless joystick types
Input devices like rudders or pedals are joystick-like; they don't have
buttons, but axes like RX, THROTTLE, or RUDDER. These don't interfere with
other device types with absolute axes (touch screens, touchpads, and
accelerometers), so it's fairly safe to mark them as ID_INPUT_JOYSTICK and thus
hand out dynamic ACLs to the user.

https://bugs.freedesktop.org/show_bug.cgi?id=70734
2014-03-17 12:02:40 -04:00
Lukas Nykryn
10e0d09f13 udev: properly detect reference to unexisting part of PROGRAM's result 2014-03-17 12:01:47 -04:00
Josh Triplett
7b85b243b2 Use strlen even for constant strings
GCC optimizes strlen("string constant") to a constant, even with -O0.
Thus, replace patterns like sizeof("string constant")-1 with
strlen("string constant") where possible, for clarity.  In particular,
for expressions intended to add up the lengths of components going into
a string, this often makes it clearer that the expression counts the
trailing '\0' exactly once, by putting the +1 for the '\0' at the end of
the expression, rather than hidden in a sizeof in the middle of the
expression.
2014-03-17 12:01:15 -04:00
Miklos Vajna
df97ff7456 udev: spelling fixes 2014-03-17 11:59:52 -04:00
Anthony G. Basile
c5a77c7d10 Fix issue #87: fails to build on linux headers 3.13
Commit 80b10107cb added #include <linux/fcntl.h> in
src/accelerometer and friends for builds on uclibc.
This only works with glibc and musl systems with
linux headers 3.9 but fails with linux headers 3.13.

We keep <linux/fcntl.h> but drop <fcntl.h>.

Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-03-15 08:16:41 -04:00
Anthony G. Basile
ac1546da71 UPSTREAM.notes: updated 2014-03-13 15:03:11 -04:00
Anthony G. Basile
e0aa59ede2 configure.ac: bump to version 1.5.2
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-03-09 13:43:28 -04:00
Lennart Poettering
01e635e556 udev-builtin-blkid: modernizations and minor fixes 2014-03-09 13:31:46 -04:00
Anthony G. Basile
80b10107cb builtins: add <linux/fcntl.h> for uclibc 2014-03-09 13:16:31 -04:00
Marcel Holtmann
81ecc0c3e7 hwdb: Update database of Bluetooth company identifiers
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-03-05 15:06:51 -05:00
Anthony G. Basile
3836f0afa1 configure.ac: bump to version 1.5.1 2014-03-04 09:32:50 -05:00
Anthony G. Basile
28b8a50320 rules: retain, but do not install 80-net-setup-link.rules
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-03-02 09:42:54 -05:00
Anthony G. Basile
e906d02b61 configure.ac: bump to version 1.5 2014-02-28 17:35:51 -05:00
Anthony G. Basile
c51c39f7a9 Enable some missed udev rules
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-02-28 17:14:31 -05:00
Kieran Clancy
a160f72144 hwdb: keymaps for Samsung 900X3E/900X3F
Keymaps for Samsung 900X3E and 900X3F should be the same as for other
models in the series.

I have also moved the comment for '# Series 9' to the right place

Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-02-28 16:57:02 -05:00
Lukas Nykryn
53f2bc3b0d udev/rules: setup tty permissions and group for sclp_line, ttysclp and 3270/tty
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
2014-02-28 16:53:26 -05:00