Bug 468692 - No longer getting printer devices
Summary: No longer getting printer devices
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: hal
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Richard Hughes
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: F10Blocker, F10FinalBlocker 468408
TreeView+ depends on / blocked
 
Reported: 2008-10-27 14:00 UTC by Tim Waugh
Modified: 2008-10-28 10:11 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2008-10-27 17:54:48 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
hal-device-ordering.patch (508 bytes, patch)
2008-10-27 16:02 UTC, Tim Waugh
no flags Details | Diff

Description Tim Waugh 2008-10-27 14:00:23 UTC
Description of problem:
Plugging in a printer no longer automatically configures a queue, because hal is failing to fill in 'printer.*' attributes.

Version-Release number of selected component (if applicable):
hal-0.5.12-7.20081022git.fc10.x86_64

How reproducible:
100%

Steps to Reproduce:
1.Plug in a printer and wait
2.lpstat -s -- no queue configured
3.lshal -t | grep printer
  
Actual results:
No printer configured, no printer listed.

Expected results:
Printer configured automatically.

Additional info:
Works fine if I downgrade to hal-0.5.12-5.20081013git.fc10.

Comment 1 Tim Waugh 2008-10-27 14:02:24 UTC
Here's a 'diff good-tree bad-tree' from 'lshal -t' output:

@@ -1,6 +1,7 @@
 computer
-  computer_logicaldev_input
+  net_9e_f2_49_24_ac_23
   computer_logicaldev_input_0
+  computer_logicaldev_input
   computer_alsa_timer
   computer_oss_sequencer_0
   computer_oss_sequencer
@@ -8,11 +9,13 @@
   computer_logicaldev_input_1
   acpi_CPU0
   acpi_CPU1
+  net_computer_loopback
   pnp_PNP0c02
   pnp_PNP0c01_0
   pnp_PNP0501
     pnp_PNP0501_serial_platform_0
   pnp_PNP0401
+    ppdev_parport0
   pnp_PNP0700
   pnp_PNP0b00
   pnp_PNP0800
@@ -46,16 +49,16 @@
       pci_8086_27c1_scsi_host_scsi_host
       pci_8086_27c1_scsi_host_scsi_device_lun0
         storage_serial_SATA_WDC_WD800GD_75F_WD_WMAKE2520002
-          volume_uuid_9ef7a062_e8de_4c8d_be19_b09b82fe74d1
           volume_uuid_3c2996eb_4f80_4c31_86f3_94dec4fa03be
           volume_uuid_ef4d79c3_5a5a_4108_a814_48543ec16a7b
+          volume_uuid_9ef7a062_e8de_4c8d_be19_b09b82fe74d1
         pci_8086_27c1_scsi_host_scsi_device_lun0_scsi_generic
   pci_8086_27df
     pci_8086_27df_scsi_host_0
     pci_8086_27df_scsi_host
       pci_8086_27df_scsi_host_scsi_host
       pci_8086_27df_scsi_host_scsi_device_lun0
-        storage_model_HL_DT_ST_DVD___RW_GWA4164B
+        storage_model_DVD__RW_GWA4164B
         pci_8086_27df_scsi_host_scsi_device_lun0_scsi_generic
   pci_8086_27b8
   pci_8086_244e
@@ -66,7 +69,7 @@
       usb_device_50d_234_noserial
         usb_device_3f0_3304_US05N1J00XLG
           usb_device_3f0_3304_US05N1J00XLG_if0
-            usb_device_3f0_3304_US05N1J00XLG_if0_printer_US05N1J00XLG
+            usb_device_ffffffff_ffffffff_noserial
         usb_device_50d_234_noserial_if0
       usb_device_1d6b_2_0000_00_1d_7_if0
   pci_8086_27cb

This last hunk seems to be the most relevant.

Comment 2 Tim Waugh 2008-10-27 14:13:05 UTC
Here's the good entry (minus the hal_lpadmin-added parts):

udi = '/org/freedesktop/Hal/devices/usb_device_3f0_3304_US05N1J00XLG_if0_printer
_US05N1J00XLG'
  info.bus = 'usb'  (string)
  info.capabilities = {'printer'} (string list)
  info.category = 'printer'  (string)
  info.interfaces = {'org.freedesktop.Hal.Device.Printer'} (string list)
  info.parent = '/org/freedesktop/Hal/devices/usb_device_3f0_3304_US05N1J00XLG_i
f0'  (string)
  info.product = 'DESKJET 990C'  (string)
  info.subsystem = 'usb'  (string)
  info.udi = '/org/freedesktop/Hal/devices/usb_device_3f0_3304_US05N1J00XLG_if0_
printer_US05N1J00XLG'  (string)
  info.vendor = 'HEWLETT-PACKARD'  (string)
  linux.device_file = '/dev/usb/lp0'  (string)
  linux.hotplug_type = 2  (0x2)  (int)
  linux.subsystem = 'usb'  (string)
  linux.sysfs_path = '/sys/devices/pci0000:00/0000:00:1d.7/usb1/1-1/1-1.2/1-1.2:
1.0/usb/lp0'  (string)
  printer.commandset = {'MLC', 'PCL', 'PML'} (string list)
  printer.description = 'Hewlett-Packard DeskJet 990C'  (string)
  printer.device = '/dev/usb/lp0'  (string)
  printer.originating_device = '/org/freedesktop/Hal/devices/usb_device_3f0_3304
_US05N1J00XLG_if0'  (string)
  printer.product = 'DESKJET 990C'  (string)
  printer.serial = 'US05N1J00XLG'  (string)
  printer.vendor = 'HEWLETT-PACKARD'  (string)

and here's the bad entry:

udi = '/org/freedesktop/Hal/devices/usb_device_ffffffff_ffffffff_noserial'
  info.bus = 'usb_device'  (string)
  info.parent = '/org/freedesktop/Hal/devices/usb_device_3f0_3304_US05N1J00XLG_i
f0'  (string)
  info.product = 'Unknown (0xffffffff)'  (string)
  info.subsystem = 'usb_device'  (string)
  info.udi = '/org/freedesktop/Hal/devices/usb_device_ffffffff_ffffffff_noserial
'  (string)
  info.vendor = 'Unknown (0xffffffff)'  (string)
  linux.device_file = '/dev/usb/lp0'  (string)
  linux.hotplug_type = 2  (0x2)  (int)
  linux.subsystem = 'usb'  (string)
  linux.sysfs_path = '/sys/devices/pci0000:00/0000:00:1d.7/usb1/1-1/1-1.2/1-1.2:
1.0/usb/lp0'  (string)
  usb_device.bus_number = 0  (0x0)  (int)
  usb_device.can_wake_up = false  (bool)
  usb_device.is_self_powered = false  (bool)
  usb_device.linux.sysfs_path = '/sys/devices/pci0000:00/0000:00:1d.7/usb1/1-1/1
-1.2/1-1.2:1.0/usb/lp0'  (string)

Comment 3 Tim Waugh 2008-10-27 14:30:26 UTC
I tried commenting out the ppdev support but still no luck.

Comment 4 Tim Waugh 2008-10-27 15:44:21 UTC
Reverting all of the hald/linux/device.c changes fixes it.

Comment 5 Tim Waugh 2008-10-27 16:02:53 UTC
Created attachment 321624 [details]
hal-device-ordering.patch

Oh, it's the re-ordering that's causing it.  Here's a patch that fixes it.

Comment 6 Richard Hughes 2008-10-27 17:36:40 UTC
I've committed this upstream. I'll make a HAL snapshot now that includes this and build it into rawhide.

Comment 7 Richard Hughes 2008-10-27 17:54:48 UTC
Build as http://koji.fedoraproject.org/koji/taskinfo?taskID=906959

Comment 8 Richard Hughes 2008-10-28 09:55:44 UTC
Request from Danny (upstream) -- "Would it be possible to get a verbose log from startup in the 'bad case'?"

Thanks dude. If not, I can try and reproduce using a local git snapshot.

Comment 9 Tim Waugh 2008-10-28 10:11:13 UTC
Sure.  Let me know what I need to do for that.


Note You need to log in before you can comment on or make changes to this bug.