Hello community, here is the log from the commit of package hwinfo checked in at Fri May 11 15:44:46 CEST 2007. -------- --- hwinfo/hwinfo.changes 2007-05-03 18:40:56.000000000 +0200 +++ /mounts/work_src_done/STABLE/hwinfo/hwinfo.changes 2007-05-11 12:16:11.000000000 +0200 @@ -1,0 +2,5 @@ +Fri May 11 12:16:04 CEST 2007 - snwint@suse.de + +- sassmann: added ps3 support (#273135) + +------------------------------------------------------------------- Old: ---- hwinfo-13.33.tar.bz2 New: ---- hwinfo-13.34.tar.bz2 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ hwinfo.spec ++++++ --- /var/tmp/diff_new_pack.AM9979/_old 2007-05-11 15:44:27.000000000 +0200 +++ /var/tmp/diff_new_pack.AM9979/_new 2007-05-11 15:44:27.000000000 +0200 @@ -1,5 +1,5 @@ # -# spec file for package hwinfo (Version 13.33) +# spec file for package hwinfo (Version 13.34) # # Copyright (c) 2007 SUSE LINUX Products GmbH, Nuernberg, Germany. # This file and all modifications and additions to the pristine @@ -20,9 +20,9 @@ PreReq: /sbin/ldconfig %insserv_prereq %fillup_prereq Autoreqprov: on Summary: Hardware Library -Version: 13.33 +Version: 13.34 Release: 1 -Source: hwinfo-13.33.tar.bz2 +Source: hwinfo-13.34.tar.bz2 BuildRoot: %{_tmppath}/%{name}-%{version}-build %description @@ -89,6 +89,8 @@ %doc doc/libhd/html %changelog +* Fri May 11 2007 - snwint@suse.de +- sassmann: added ps3 support (#273135) * Thu May 03 2007 - snwint@suse.de - braille detection can no longer block libhd (#266163) - get network interface link state from sysfs ++++++ hwinfo-13.33.tar.bz2 -> hwinfo-13.34.tar.bz2 ++++++ diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/hwinfo-13.33/Changelog new/hwinfo-13.34/Changelog --- old/hwinfo-13.33/Changelog 2007-05-03 18:40:12.000000000 +0200 +++ new/hwinfo-13.34/Changelog 2007-05-11 12:15:07.000000000 +0200 @@ -1,3 +1,6 @@ +11/5/2007: v13.34 + - sassmann: added ps3 support (#273135) + 3/5/2007: v13.33 - braille detection can no longer block libhd (#266163) - get network interface link state from sysfs diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/hwinfo-13.33/src/hd/hd.h new/hwinfo-13.34/src/hd/hd.h --- old/hwinfo-13.33/src/hd/hd.h 2007-04-20 13:00:37.000000000 +0200 +++ new/hwinfo-13.34/src/hd/hd.h 2007-05-11 12:12:32.000000000 +0200 @@ -293,7 +293,7 @@ /** outside the range of the PCI values */ bus_ps2 = 0x80, bus_serial, bus_parallel, bus_floppy, bus_scsi, bus_ide, bus_usb, - bus_adb, bus_raid, bus_sbus, bus_i2o, bus_vio, bus_ccw, bus_iucv + bus_adb, bus_raid, bus_sbus, bus_i2o, bus_vio, bus_ccw, bus_iucv, bus_ps3_system_bus } hd_bus_types_t; /** @} */ diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/hwinfo-13.33/src/hd/pci.c new/hwinfo-13.34/src/hd/pci.c --- old/hwinfo-13.33/src/hd/pci.c 2007-02-21 12:54:16.000000000 +0100 +++ new/hwinfo-13.34/src/hd/pci.c 2007-05-11 12:12:32.000000000 +0200 @@ -50,6 +50,8 @@ static void hd_read_macio(hd_data_t *hd_data); static void hd_read_vio(hd_data_t *hd_data); static void hd_read_xen(hd_data_t *hd_data); +static void hd_read_ps3_system_bus(hd_data_t *hd_data); +static void hd_read_platform(hd_data_t *hd_data); static void add_xen_network(hd_data_t *hd_data); static void add_xen_storage(hd_data_t *hd_data); @@ -85,6 +87,12 @@ PROGRESS(5, 0, "xen"); hd_read_xen(hd_data); + PROGRESS(6, 0, "ps3"); + + hd_read_ps3_system_bus(hd_data); + + PROGRESS(7, 0, "platform"); + hd_read_platform(hd_data); } @@ -727,6 +735,134 @@ free_str_list(sf_bus); } +/* + * Get platform data from sysfs. + */ +void hd_read_platform(hd_data_t *hd_data) +{ + char *s, *platform_name, *platform_type; + int scsi_cnt = 0; + hd_t *hd; + str_list_t *sf_bus, *sf_bus_e; + char *sf_dev; + + sf_bus = reverse_str_list(read_dir("/sys/bus/platform/devices", 'l')); + + if(!sf_bus) { + ADD2LOG("sysfs: no such bus: platform\n"); + return; + } + + for(sf_bus_e = sf_bus; sf_bus_e; sf_bus_e = sf_bus_e->next) { + sf_dev = new_str(hd_read_sysfs_link("/sys/bus/platform/devices", sf_bus_e->str)); + + ADD2LOG( + " platform device: name = %s\n path = %s\n", + sf_bus_e->str, + hd_sysfs_id(sf_dev) + ); + + platform_name = platform_type = NULL; + + if((s = get_sysfs_attr_by_path(sf_dev, "modalias"))) { + platform_type = canon_str(s, strlen(s)); + ADD2LOG(" type = \"%s\"\n", platform_type); + } + + if( + platform_type && ( !strcmp(platform_type, "ps3_storage") ) + ) { + hd = add_hd_entry(hd_data, __LINE__, 0); + hd->bus.id = bus_ps3_system_bus; + + hd->vendor.id = MAKE_ID(TAG_PCI, 0x104d); /* Sony */ + + hd->base_class.id = bc_storage; + hd->sub_class.id = sc_sto_scsi; + hd->slot = scsi_cnt++; + hd->device.id = MAKE_ID(TAG_SPECIAL, 0x1000); /* PS3_DEV_TYPE_STOR_DISK */ + str_printf(&hd->device.name, 0, "PS3 storage %d", hd->slot); + + hd->rom_id = new_str(platform_name ? platform_name + 1 : 0); /* skip leading '/' */ + + hd->sysfs_id = new_str(hd_sysfs_id(sf_dev)); + hd->sysfs_bus_id = new_str(sf_bus_e->str); + s = hd_sysfs_find_driver(hd_data, hd->sysfs_id, 1); + if(s) add_str_list(&hd->drivers, s); + } + + free_mem(sf_dev); + } + + free_str_list(sf_bus); +} + + + +/* + * Get ps3 data from sysfs. + */ +static void hd_read_ps3_system_bus(hd_data_t *hd_data) +{ + char *s, *ps3_name, *ps3_type; + int eth_cnt = 0; + hd_t *hd; + str_list_t *sf_bus, *sf_bus_e; + char *sf_dev; + + sf_bus = reverse_str_list(read_dir("/sys/bus/ps3_system_bus/devices", 'l')); + + if(!sf_bus) { + ADD2LOG("sysfs: no such bus: ps3_system_bus\n"); + return; + } + + for(sf_bus_e = sf_bus; sf_bus_e; sf_bus_e = sf_bus_e->next) { + sf_dev = new_str(hd_read_sysfs_link("/sys/bus/ps3_system_bus/devices", sf_bus_e->str)); + + ADD2LOG( + " ps3 device: name = %s\n path = %s\n", + sf_bus_e->str, + hd_sysfs_id(sf_dev) + ); + + ps3_name = ps3_type = NULL; + + if((s = get_sysfs_attr_by_path(sf_dev, "modalias"))) { + ps3_name = canon_str(s, strlen(s)); + ADD2LOG(" modalias = \"%s\"\n", ps3_name); + } + + if( + ps3_name && ( + !strcmp(ps3_name, "ps3:3") || + !strcmp(ps3_name, "gelic_net") + ) + ) { + hd = add_hd_entry(hd_data, __LINE__, 0); + hd->bus.id = bus_ps3_system_bus; + + hd->vendor.id = MAKE_ID(TAG_PCI, 0x104d); /* Sony */ + + hd->base_class.id = bc_network; + hd->sub_class.id = 0; /* ethernet */ + hd->slot = eth_cnt++; + hd->device.id = MAKE_ID(TAG_SPECIAL, 0x1003); /* PS3_DEV_TYPE_SB_GELIC */ + str_printf(&hd->device.name, 0, "PS3 Ethernet card %d", hd->slot); + + hd->rom_id = new_str(ps3_name ? ps3_name + 1 : 0); /* skip leading '/' */ + + hd->sysfs_id = new_str(hd_sysfs_id(sf_dev)); + hd->sysfs_bus_id = new_str(sf_bus_e->str); + s = hd_sysfs_find_driver(hd_data, hd->sysfs_id, 1); + if(s) add_str_list(&hd->drivers, s); + } + + free_mem(sf_dev); + } + + free_str_list(sf_bus); +} /* * Get xen (network & storage) data from sysfs. diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/hwinfo-13.33/src/ids/src/monitor new/hwinfo-13.34/src/ids/src/monitor --- old/hwinfo-13.33/src/ids/src/monitor 2006-01-18 12:22:35.000000000 +0100 +++ new/hwinfo-13.34/src/ids/src/monitor 2007-05-08 16:28:00.000000000 +0200 @@ -2390,6 +2390,9 @@ +device.name DATA SYSTEMS VISUAL SENSATION VS-19SN +driver.display |50-120|30-95 + vendor.id LEN ++vendor.name Lenovo + vendor.id LKM +vendor.name AZALEA diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/hwinfo-13.33/VERSION new/hwinfo-13.34/VERSION --- old/hwinfo-13.33/VERSION 2007-04-19 16:30:10.000000000 +0200 +++ new/hwinfo-13.34/VERSION 2007-05-11 12:14:22.000000000 +0200 @@ -1 +1 @@ -13.33 +13.34 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Remember to have fun... --------------------------------------------------------------------- To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-commit+help@opensuse.org