Age | Commit message (Collapse) | Author |
|
https://bugzilla.redhat.com/show_bug.cgi?id=1038015
The problem seems to be that the your virtual DVD is emulating a really
old DVD device, and doing it kind of strangely.
> dracut:# /lib/udev/cdrom_id --debug /dev/sr0
> probing: '/dev/sr0'
> INQUIRY: [IMM ][Virtual CD/DVD ][0316]
> GET CONFIGURATION failed with SK=5h/ASC=24h/ACQ=00h
So your virtual drive rejects the GET CONFIGURATION command as illegal.
Other pre-MMC2 drives that don't accept this command usually return the
error
SK=5h,ASC=20h (invalid/unsupported command code), in which case cdrom_id
tries an older method, and then ID_CDROM_MEDIA_TRACK_COUNT_DATA gets set
and all the /dev/disk/by-label (etc) links get set up.
The virtual drive returns the error SK=5h,ASC=24h (invalid field in
Command Descriptor Block), which cdrom_id doesn't handle, so it gives up
and the links never get made.
The ideal solution would be to make the IMM to emulate a device that's
less than 15 years old, but I'm not going to hold my breath waiting for
that.
So probably cdrom_id should also use the old MMC fallback when the error
is SK=5h,ASC=24h, and then all of this would work as expected.
Suggested-by:Luca Miccini <lmiccini@redhat.com>
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
As pointed-out by clang -Wunreachable-code.
No behaviour changes.
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
For gudev -> gudevdevice:
- Add support for get_sysfs_attr_keys()
- Add support for has_sysfs_attr()
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
If -flto is used then gcc will generate a lot more warnings than before,
among them a number of use-without-initialization warnings. Most of them
without are false positives, but let's make them go away, because it
doesn't really matter.
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Resolve spotted issues related to missing or extraneous commas, dashes.
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Use PID_FMT/USEC_FMT/... in more places.
Also update logind error messages to print the full path to a file that
failed. This should make debugging easier for people who do not know
off the top of their head where logind stores it state.
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
In trying to track down a stupid linker bug, I noticed a bunch of
memset() calls that should be using memzero() to make it more "obvious"
that the options are correct (i.e. 0 is not the length, but the data to
set). So fix up all current calls to memset(foo, 0, length) to
memzero(foo, length).
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
The nodes usually do not exist, so handle the next item instead of
skipping the entire rule.
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
When configure --enable-selinux, we hit a compile time error
with a missing definition of FORMAT_TIMESPAN_MAX. This
was imported from upstream's src/shared/time-util.h into
our src/libudev/util.h.
Thanks Amadeusz Sławiński <amade@asmblr.net>
X-Gentoo-Bug: 499252
X-Gentoo-Bug-URL: https://bugs.gentoo.org/499252
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
POSIX says:
Note that sysconf(_SC_GETGR_R_SIZE_MAX) may return -1 if there is no
hard limit on the size of the buffer needed to store all the groups
returned.
The example from POSIX uses a default buffer size of 1024 in that case.
Signed-off-by: Michael Forney <mforney@mforney.org>
|
|
Signed-off-by: Michael Forney <mforney@mforney.org>
|
|
while theoretically a nice interface, qsort_r on GLIBC was
implemented with a prototype that shuffles the argument order
around when compared to the traditional BSD implementations,
yielding in 2 separate incompatible implementations.
even worse, the arguments are all of pointer type so one would
not even notice that the order is wrong and so this would yield
in crashes or silent memory corruption.
thus musl does not implement it, because configure scripts would
check for its existance and use it unconditionally, even when
assuming the BSD version.
a more portable solution is to use TLS via __thread, which any
modern GCC should provide. (even 3.4.6 on x86/x86_64 does so).
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
this is a glibc specific alias for realpath(path, NULL).
to be portable, we need to use the real thing which is even less
verbose.
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
These commits were authored by
Zbigniew Jędrzejewski-Szmek
Tom Gundersen
Kay Sievers
Lennart Poettering
Shawn Landden
Daniel Buch
Martin Pitt
Karel Zak
Yang Zhiyong
Note: udev_builtin_net_setup_link has *not* been imported. Also
still missing from udev-builtin is udev_builtin_uaccess.
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
This matches the bcma support in the network device naming.
Eventually wa want to make sure ID_PATH is equivalent to ID_NET_NAME_PATH,
so we never need to match on the latter.
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
I want to use this from a bulitin in a subsequent patch.
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Since the invention of read-only memory, write-only memory has been
considered deprecated. Where appropriate, either make use of the
value, or avoid writing it, to make it clear that it is not used.
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
bInterfaceSubClass == 5 is not a "floppy"; just identify the obsolete
QIC-157 interface as "generic".
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Always cache the results, and bypass low-level security calls when
the respective subsystem is not enabled.
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Set some_transport = true to prevent scm devices from being ignored.
Suggested-by: Harald Hoyer <harald@redhat.com>
Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com>
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
https://bugs.archlinux.org/task/36950
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Uevents are events of the host, which should not leak into a container.
Containers do not support hotplug at the moment, and devices and uevents
are not namespace aware.
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Clang is a bit more strict wrt format-nonliterals:
http://clang.llvm.org/docs/LanguageExtensions.html#format-string-checking
Adding these extra printf attributes also makes gcc able to find more
problems. E.g. this patch uncovers a format issue in udev-builtin-path_id.c
Some parts looked intetional about breaking the format-nonliteral check.
I added some supression for warnings there.
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
https://bugs.freedesktop.org/show_bug.cgi?id=72164
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Returning anything else but NULL would suggest the caller's reference
might still be valid, but it isn't, because the caller just invoked
_unref() after all.
This turns the return value into a typesafe shortcut that allows
unreffing and resetting a reference in one line. In contrast to
solutions for this which take a pointer to a pointer to accomplish the
same this solution is just syntactic sugar the developer can make use of
but doesn't have to, and this is particularly useful when immediately
unreffing objects returned by function calls.
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
|
|
|
|
|