Age | Commit message (Collapse) | Author | Files | Lines |
|
Fixed storage.bus handling for SCSI. Prevent fall through to PCI as
storage bus. Current HAL marked SCSI storage devices which are not
usb or ieee1394 get marked with storage.bus=pci and not as scsi.
|
|
Add hotplug support for e-SATA (bnc#576506); hotpluggable flag
is set if ahci_cmd_port is exported in sysfs (available in the
recent kernel)
|
|
Fixed possible sscanf() crashes caused by hal_util_get_last_element()
returning a NULL pointer (in rare error case) which was used unchecked
in sscanf() calls.
|
|
Added breaks to detection of storage.bus for ccw, vio and pci
as e.g. in case of usb or ieee1394 to leave the while loop as
soon as possible.
|
|
Fixed if/else block to find storage bus. Since info.subsystem
is a string, there is no need to check for USB after SCSI. Added
extra USB if block to the SCSI block as 'else if' to prevent
unneeded double check.
|
|
Fixed indentation in blockdev.c
|
|
Fixed commit 141ca8cd7b768ddefa1bfaa563cbef4337e32b7c:
add void as return type to hotplug_event_begin_add_blockdev, which was
removed with this previous commit.
|
|
|
|
Signed-off-by: Richard Hughes <richard@hughsie.com>
|
|
Fixed usage of deprected g_io_channel_seek(), replaced
it with g_io_channel_seek_position().
|
|
Don't assume that the parent of a volume has storage capability; e. g.
if we are an MD partition then this is the case as we were re-parented
to the root computer device object earlier.
FD#21603
|
|
Removed remove unused pointer to struct mntent returned from
getmntent_r() .
|
|
Fixed some memory leaks on normal operation. Some pointers were
being lost when being overwritten by new values, others were just
not being freed.
|
|
Improved HAL performance for filesystem detection. Call libvolume_id
functions in the volume prober to get the following information only
if we have no udev information about the filesystem:
- volume.fsusage
- volume.fstype
- volume.fsversion
- volume.uuid
- volume.label
HAL now simply use the already in the HotplugEvent stored information
from udev if available, since udev already called libvolume_id to get
these info. With this change HAL needs to probe only CD/DVD media and
maybe fakevolume related volumes.
|
|
This reverts commit 7aca1f3fefefd3c760636aabcff1e25946ab6391.
Reverted the change to prevent trouble with CD/DVD media (because
they are fakevolumes and udev tell us no information about the
filesystem on insert the media).
|
|
This adds basic memory stick support to hal. It's enough to get
automounting up, but it doesn't expose any of the memory stick specific
attributes yet since I'm not sure which of them are especially useful.
|
|
Cleaned up handling of volume filesystem information. Don't call
libvolume_id functions in the volume prober to get the following
information:
- volume.fsusage
- volume.fstype
- volume.fsversion
- volume.uuid
- volume.label
HAL now simply use the already in the HotplugEvent stored information
from udev, since udev already called libvolume_id to get these info.
|
|
Fixed md related code to find/set the parent devie in
hotplug_event_begin_add_blockdev().
|
|
Added support for HP Smart Array CCISS block devices, which are
in recent kernel versions virtual block/storage devices and no
longer pci based (also if the Smart Array controller is a PCI
device).
|
|
This reverts commit 52390cd9e5f1ce48eb9b486044369f0e10a7865b.
|
|
Added support for bdi bases (virtual) block devices as e.g. cciss
storage devices on newer kernel versions.
Changed device handling to find parent of a virtual bdi block device
by checking either target of the bdi link (if available) or search
for existing devices with the parent dir as sysfs path.
Allow bdi as storage bus.
|
|
Allow also PCI as possible storage.bus, needed e.g. on older
kernel versions to detect cciss storage devices.
|
|
The inserts the sysfs path at the right position when calling
udevadm info.
|
|
Use udevadm instead of (deprecated) udevinfo. Adapted/fixed version
of a patch contributed by Lucas Hazel <lucas@die.net.au> via HAL ML.
|
|
Remove storage.model property from volumes. This property make no
sense on a volume device and should be used only within the storage
namespace.
|
|
Fix mounting of devices with a very large number of reported blocks by
making it a 64 bit property. (https://launchpad.net/bugs/209483)
|
|
This sets Xen storage drive type based on contents of the devices
sysfs media file. (Creation of sysfs media file was pushed into
upstream Xen 07-28-08.)
|
|
Fixed a bunch of compiler warnings from the Intel compiler
(cce/icc 10.1.015). Closed a small memory leak in
linux/hal-file-monitor.c
|
|
Cleaned up the code. Removed all separate calls of
hal_device_property_set_string (device, "info.udi", udi) so set the
info.udi property of a device. moved the call to hal_device_set_udi(),
this is now more consistent.
|
|
Introduces hald_compute_udi which computes a udi thats unique in both the
tdl and gdl and uses it everywhere relvent. This is necessary when we're
processing events in parallel as otherwise its possible to get a race condition
with two devices added with the same name. As part of this patch,
hal_util_compute_udi grwos a varargs version and no longer makes the computer
udi unique. I've also added a hal_util_make_udi_unique for use in those places
where hal_util_compute_udi was only used to check a udi was unique when
inserting into the gdl.
|
|
Using g_slice should be better (and makes for cleaner code) than our current
HotplugEvent pool.
|
|
Generate better UDIs for virtual storage devices (like vio bus devices).
|
|
Updated spec for existing storage.bus types (pcmcia,mmc,ccw,vio)
|
|
Added vio storage bus support. Set storage.bus and storage.drive_type
for vio storage devices.
|
|
As you probably know already, glib 2.14 introduced variants of the
g_timeout_add() functions that operate at whole second granularity. This
allows timers to be grouped, which results in a more power and CPU
efficient behavior.
Attached is a patch that adds a configure check for GLib 2.14 and
changes some code (notably in the Linux specific parts) to use the new
functions when possible.
|
|
Removed deprecated *.physical_device property from hal. The key reached
end of lifetime with 2008-03-01 and was replaced by *.originating_device.
|
|
Hello all,
Linear MD device are not syncable, and so there is no sync-action in
/sys/block/md0/md/ (at least i don't have it).
In the actual code, MD device are ignored if this file is not found.
The attched path fix that issue.
Cheers,
Mertens Florent
|
|
Commited updated and tested patch from Richard Hughes <hughsient@gmail.com>
to use hardcoded paths to /sys and /proc instead of all the not really
needed calls of get_hal_{proc,sysfs}_path() because sysfs is always
under /sys and proc under /proc. This remove also several g_strlcat()/
g_strlcpy() calls and some variables.
|
|
This allows us to avoid waking up libata all the freaking time.
Also, to do this refactor and rewire some of the support for "change"
uevents in the hal core.
See https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=halpolling
for further discussion.
|
|
/proc/ide is optional in 2.6.22; let hald get media information from
sysfs if /proc/ide does not exist. May be we can always do it instead.
|
|
Free volumelabel introduced with commit 2d1d72e8 as pointed
out by Iulian Ciorascu <iulica@box.co.uk>.
|
|
This fixes fd.o #11401 by replacing '/' in volume labels with '_' if they
get part of the UDI. This should avoid trouble with D-Bus.
|
|
|
|
Since pictures says more than a thousand words...
http://people.freedesktop.org/~david/hal-md-normal.png
http://people.freedesktop.org/~david/hal-md-degraded.png
http://people.freedesktop.org/~david/hal-md-recover.png
This patch only adds detection by exploiting the fact that in Linux
2.6.19 and later /proc/mdstat is pollable. Later on we'll add D-Bus
interfaces to add methods for assembly, teardown of RAID arrays as
well as adding hot spares.
I wonder if it's worth abstracting Software RAID so FreeBSD and
Solaris can implement this too? It's probably too
different.. Thoughts?
|
|
On 4/23/07, David Zeuthen <david@fubar.dk> wrote:
> On Sun, 2007-04-22 at 14:01 +0200, Kay Sievers wrote:
> > But we may just want to change HAL to handle mnt_dir == "/" as a
> > special case, instead of assuming the name to be a device-node. That
> > should solve the real problem we are seeing here.
>
> I'm fine taking a patch to do that. Thanks!
Does this work for you Doug?
Thanks,
Kay
|
|
See RH #227593
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=227593
The fix was trivial as the bug was so obvious - we simply forget to process
hotplug events when we detect that HAL didn't mount the device.
|
|
This should fix some problems when mounted devices are yanked out. At
least that's the problem I had with my new 4GB SanDisk U3 Cruzer
Micro. I have two partitions on it - one cleartext vfat partition and
one LUKS partition. When yanking the stick, HAL nicely reported that
the cleartext partition was unmounted even though it was still
mounted. Which is a lie.
There's a race we don't handle. In particular, the device node for a
device, such as /dev/sdb1, may have been unlinked by udev but the
device is still mounted and we haven't processed the uevent for that
deletion from udev. So when we process entries from /proc/mounts we
fail to stat the device node /dev/sdb1 and this leads us to assume the
device is not mounted. That's wrong.
So in this case fall back to comparing on device names rather than
pretending the device is not mounted as that's what will happen if we
just skip this /proc/mounts entry.
The reason it's nicer to compare on major:minor, and why we do that in
general, is that /proc/mounts is *broken by design* - it contains the
*device name* passed to mount(2) which in some cases may be a
symlink. In fact, on many distros it's common to see /proc/mounts
contain /dev/root as the device for /.
|
|
Current systems make it almost impossible to distinguish between
"virtual" and "physical" devices. Current HAL, just like the Linux
kernel, tries to export such properties - which in reality, is almost
impossible to get right. The growing use of virtualization will just
make it even more incorrect.
HAL also carries, just like the Linux kernel, completely misleading bus
names like: platform-bus, xen-bus, usb_device-bus, ... Most of these
subsystems are no bus at all, and will never be one.
Renames:
info.bus -> info.subsystem
*.physical_device -> *.originating_device
The old values are deprecated, but still available and kept as long as
needed, but will be removed some day.
|
|
This adds a notify callback for when hald_runner has finished calling a callout.
For linux, we install hotplug_event_process_queue as the notify, and modify hotplug_event_process_queue to iterate the queue. All recrursive calls to hotplug_event_process_queue are removed. This results in massive stack and a not inconsiquential heap savings.
|
|
linux.sysfs_path_device is no longer needed internally in HAL.
Removing without going through deprectation process as this key was documen
as only used internally and not guaranteed to exist, so noone should be usi
it.
Also fixes problems with mmc and scsi devices getting incorrectly parented in
the device tree.
|