Commit Graph
57095 Commits
Author SHA1 Message Date
Yin Kangkai 08f11597f2 udevd: create static device links only when the target exists
For example, not all systems have PROC_KCORE enabled. Avoid a broken symbolic
link in those cases.

Signed-off-by: Yin Kangkai <kangkai.yin@intel.com>
Signed-off-by: Martin Pitt <martin.pitt@ubuntu.com>
2010-08-08 20:35:46 +02:00
Yin Kangkai 40929a0222 udevd: fix unref'ing of device in error path
Signed-off-by: Yin Kangkai <kangkai.yin@intel.com>
Signed-off-by: Martin Pitt <martin.pitt@ubuntu.com>
2010-08-08 20:29:13 +02:00
Jan Drzewiecki 45b1d780b9 cdrom_id: No "next session" for "other" media state
"other" is known to apply to DVD-RAMs, where sessions can't be appended.

Signed-off-by: Martin Pitt <martin.pitt@ubuntu.com>
2010-08-08 19:22:13 +02:00
Jan Drzewiecki a6b03c0961 cdrom_id: Also apply format check to DVD-RW
Extend the DVD+RW/DVD-RAM check in commit 1ef6c9e to also cover DVD-RW, since
in "restricted overwrite" mode they behave similar to DVD+RW.

Signed-off-by: Martin Pitt <martin.pitt@ubuntu.com>
2010-08-08 19:19:07 +02:00
Jan Drzewiecki d83dfabe0d cdrom_id: Handle pre-MMC2 drives
Those do not yet support the 0x46 "GET CONFIGURATION" support. If we have
those, fall back to the 0x51 "READ DISC INFORMATION" call. This can only
differentiate between CD-RW and CD-R, but first that's better than a complete
detection failure, and second, those old drives likely don't support more
modern media in the first place.

https://launchpad.net/bugs/502143

Signed-off-by: Martin Pitt <martin.pitt@ubuntu.com>
2010-08-08 17:57:47 +02:00
Jan Drzewiecki 1ef6c9e9f0 cdrom_id: Fix detection of reblanked DVD+RW and DVD-RAM
Once formatted, DVD+RW and DVD-RAM discs are always reported "complete" by the
drive. Check the if the Volume Descriptor or Volume Descriptor Anchor sectors
are empty, and if so, set the status to blank. If the disc is unformatted the
blank status is maintained and no reads are issued. If the disc is formatted and
read command fails, the status remains set to complete to avoid accidental
blanking.

Bug-Ubuntu: https://launchpad.net/bugs/581925

Signed-off-by: Martin Pitt <martin.pitt@ubuntu.com>
2010-08-08 17:47:08 +02:00
Lennart Poettering 0a9962a1df man: minor man page fix 2010-08-07 18:09:39 +02:00
Michal Schmidt 4a4d6b4b31 systemctl: fix parsing of DBus reply in 'dot'
"systemctl dot" has been broken since the addition of the "Following="
property.
2010-08-07 18:08:03 +02:00
Lennart Poettering 485ccf9a5b man: minor man page fix 2010-08-06 21:36:58 +02:00
Lennart Poettering 4502d22cb8 util: when formatting timestamps return '0' for 0 timestamps instead of empty string 2010-08-06 21:34:11 +02:00
Lennart Poettering c593cfe164 sd-daemon: fix compilation on old systems lacking SOCK_CLOEXEC 2010-08-06 21:34:11 +02:00
Kay Sievers b9911f4434 update fixme 2010-08-06 13:23:50 +02:00
Lennart Poettering 7e551fbd68 build-sys: prepare new release 2010-08-06 12:15:54 +02:00
Lennart Poettering 6908d3842a man: document %triggerin usage 2010-08-06 11:59:37 +02:00
Lennart Poettering ee6cb28869 device: properly handle devices that are referenced before they show up 2010-08-06 04:17:51 +02:00
Lennart Poettering 3c661fadd5 cgroup: if the system bus cannot be found, send cgroup empty msg directly to init proces 2010-08-06 03:21:50 +02:00
Lennart Poettering 2e81c8a557 manager: downgrade a few log msgs regarding conflicting but fixable jobs 2010-08-06 02:58:46 +02:00
Lennart Poettering 75d287d3ae automount: order automount units after fsck, too 2010-08-06 02:23:45 +02:00
Lennart Poettering 8519e861a8 units: add missing fsck.target file 2010-08-06 01:32:16 +02:00
Lennart Poettering 922cc00119 units: split fsck.target from sysinit.target for suse compat 2010-08-06 01:30:20 +02:00
Lennart Poettering 0ff4cdd967 main: automatically spawn a getty on the kernel configured serial console 2010-08-06 00:42:24 +02:00
Lennart Poettering 48a21c9b37 manager: fix conflicting job check 2010-08-05 20:49:35 +02:00
Lennart Poettering 674a6e4d0c manager: when breaking ordering cycle show full cycle loop 2010-08-05 20:39:45 +02:00
Lennart Poettering 30609d9c18 units: always send HUP when dealing with shells/gettys/logins 2010-08-05 20:29:11 +02:00
Lennart Poettering d4054675b1 service: read special startup dirs only on the respective distros 2010-08-05 20:28:51 +02:00
Lennart Poettering 95978cf8a6 selinux: minor error handling fix 2010-08-05 19:50:03 +02:00
Lennart Poettering eeaafddcb5 service: always sort services from suse B runlevel before services from normal runlevels 2010-08-05 19:50:03 +02:00
Michal Schmidt a042efad57 reboot: handle -p switch properly
https://bugzilla.redhat.com/show_bug.cgi?id=618678
2010-08-05 19:50:03 +02:00
Lennart Poettering 6319292f15 selinux: fix labels only when configured for it 2010-08-05 19:50:02 +02:00
Kay Sievers 232f180397 udev-acl: remove specific device matches from the rules file
We should do only do classes of devices, not individual pieces
of hardware.

There is no way for us to manage this in the long term, and it needs
to be thought through what we want here, but it surely isn't a list of
smartphones in the udev source tarball installed on all systems.
2010-08-05 18:55:57 +02:00
Kay Sievers 7d49c54770 units: getty - suse: login wants SIGHUP 2010-08-04 18:56:35 +02:00
Kay Sievers 00a11ba982 units: suse - reboot: do not wait for tty 2010-08-04 14:21:01 +02:00
Lennart Poettering 183ae5f99b reboot: don't wait for input tty 2010-08-04 14:17:18 +02:00
Michal Schmidt 9ac90ae153 udev-acl: really fix ACL assignment in CK events
The previous fix for udev-acl was incomplete. The ACL were not properly
assigned to the new user when switching from root's session because of
the test for 'uid != 0'.

Centralize the special handling of root to a single place (in set_facl).

https://bugzilla.redhat.com/show_bug.cgi?id=608712
2010-08-04 12:01:53 +02:00
Lennart Poettering 804bbed8f4 prepare new release 2010-08-04 01:30:40 +02:00
Lennart Poettering ccbe77e993 units: remove redundant ordering dependency 2010-08-04 01:27:26 +02:00
Lennart Poettering 5b1fe56a8b selinux: rework selinux tests a little 2010-08-04 01:07:38 +02:00
Lennart Poettering f7f4cccb2a selinux: fix if vs. ifdef mixup 2010-08-04 00:40:19 +02:00
Lennart Poettering 14a35a84fa units: make sure that prefdm wins over the getty if both are pulled in 2010-08-03 23:58:23 +02:00
Lennart Poettering a48bcc46be units: add conflicts between prefdm and getty@tty1 to avoid race for tty1 2010-08-03 23:53:17 +02:00
Daniel J Walsh 56cf987fe7 Systemd is causing mislabeled devices to be created and then attempting to read them.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 07/28/2010 05:57 AM, Kay Sievers wrote:
> On Wed, Jul 28, 2010 at 11:43, Lennart Poettering
> <lennart@poettering.net> wrote:
>> On Mon, 26.07.10 16:42, Daniel J Walsh (dwalsh@redhat.com) wrote:
>>> tcontext=system_u:object_r:device_t:s0 tclass=chr_file
>>> type=1400 audit(1280174589.476:7): avc:  denied  { read } for  pid=1
>>> comm="systemd" name="autofs" dev=devtmpfs ino=9482
>>> scontext=system_u:system_r:init_t:s0
>>> tcontext=system_u:object_r:device_t:s0 tclass=chr_file
>>> type=1400 audit(1280174589.476:8): avc:  denied  { read } for  pid=1
>>> comm="systemd" name="autofs" dev=devtmpfs ino=9482
>>> scontext=system_u:system_r:init_t:s0
>>> tcontext=system_u:object_r:device_t:s0 tclass=chr_file
>>>
>>> Lennart, we talked about this earlier.  I think this is caused by the
>>> modprobe calls to create /dev/autofs.  Since udev is not created at the
>>> point that init loads the kernel modules, the devices get created with
>>> the wrong label.  Once udev starts the labels get fixed.
>>>
>>> I can allow init_t to read device_t chr_files.
>>
>> Hmm, I think a cleaner fix would be to make systemd relabel this device
>> properly before accessing it? Given that this is only one device this
>> should not be a problem for us to maintain, I think? How would the
>> fixing of the label work? Would we have to spawn restorecon for this, or
>> can we actually do this in C without too much work?
>
> I guess we can just do what udev is doing, and call setfilecon(), with
> a context of an earlier matchpathcon().
>
> Kay
> _______________________________________________
> systemd-devel mailing list
> systemd-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/systemd-devel

Here is the updated patch with a fix for the labeling of /dev/autofs
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.14 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/

iEYEARECAAYFAkxQMyoACgkQrlYvE4MpobNviACfWgxsjW2xzz1qznFex8RVAQHf
gIEAmwRmRcLvGqYtwQaZ3WKIg8wmrwNk
=pC2e
2010-08-03 23:45:22 +02:00
Lennart Poettering 8b33e5ca72 update fixme 2010-08-03 23:29:18 +02:00
Tomasz Torcz cebf8b2092 socket: Allow selection of TCP Congestion Avoidance algorithm to socket
Hi,

attached path extends socket configurables with another
knob - TCP Congestion Avoidance selection. Linux implements
handful of those, useful in various situations. For example,
TCP Low Priority may be used by FTP service to gracefully
yield bandwidth for more important TCP/IP streams.

Until recently TCP_CONGESTION was Linux-specific, recently
FreeBSD 8 and OpenSolaris gained compatible support.
2010-08-03 23:23:47 +02:00
Lennart Poettering 07424048b5 update fixme 2010-08-03 23:22:30 +02:00
Kay Sievers 2ab7076c6f fixme update 2010-08-03 23:18:04 +02:00
Kay Sievers 939cc18afc udev-acl: properly handle CK change events for root user
mschmidt@redhat.com writes:
> since root is treated specially, it does not do anything!
> udev-acl may want to prevent removing ACLs from root, but
> it must not stop the ACLs being granted to the user of the
> new session.

https://bugzilla.redhat.com/show_bug.cgi?id=608712
2010-08-03 15:09:46 +02:00
Kay Sievers 8e5a620b17 call util_delete_path() only when we actually deleted stuff 2010-08-03 12:13:53 +02:00
Yin Kangkai 4ab3c463d4 udevd: fix short options in getopt() 2010-08-03 08:11:43 +02:00
Yin Kangkai 27f4528b9a malloc()+memset() -> calloc() 2010-08-03 08:10:26 +02:00
Yin Kangkai 1851332c08 udevd: fix some memory leaks in error path
Signed-off-by: Yin Kangkai <kangkai.yin@intel.com>
2010-08-02 12:37:55 +02:00