1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
|
2004-05-25 David Zeuthen <david@fubar.dk>
* hald/linux/block_class_device.c (read_etc_mtab): hal doesn't
close the filedescriptor when it /etc/mtab wasn't changed of the
fstat failed. Also when closing a file stream opened with fdopen,
the original fd is also closed (the fdopen function doesn't dup
the fd). So the close after fclose is wrong. Patch from Sjoerd
Simons <sjoerd@luon.net>.
(detect_fs): When fs detection fails the volume_id struct wasn't
closed, causing a mem and fd leak. And as a side effect, causing
me to be unable to open my cd writer with the eject button when
there was a blank cd inside :). Patch from Sjoerd Simons
<sjoerd@luon.net>.
2004-05-18 Joe shaw <joeshaw@novell.com>
* tools/callouts/fstab-update.sh: Use /media as long as it's there
and /mnt doesn't exist. Otherwise fallback to /mnt. Should
happily work on all distros. Patch from Sjoerd Simons
<sjoerd@luon.net>.
2004-05-17 Joe Shaw <joeshaw@novell.com>
* tools/callouts/fstab-update.sh: Guard against the script being
killed mid-execution by doing all the updates in a copy and then
moving it over later on add. Patch from Martin Waitz
<tali@admingilde.org>.
2004-05-15 Owen Fraser-Green <owen@discobabe.net>
* packaging/fedora/hal.spec: bump version to 0.2.90, D-BUS version
bump, PreReq change to include useradd and include hal.dev. Also
changed ${foo} variables to %{foo}.
2004-05-13 David Zeuthen <david@fubar.dk>
* hald/linux/block_class_device.c
(detect_media): Move disc properties into volume.disc.* namespace and
only set them for optical discs. Use disc_is_appendable() to set
volume.disc.is_appendable. Specifically, the following properties
are now available for discs (e.g. iff volume.is_disc is TRUE)
volume.disc.has_audio - TRUE iff the disc got audio tracks
volume.disc.has_data - TRUE iff the disc got data tracks
volume.disc.is_appendable - TRUE iff further data can be written
volume.disc.is_blank - TRUE iff the data is blank
volume.disc.is_rewriteable - TRUE iff the disc can be reformatted
volume.disc.type - type of disc, can assume "cd_rom", "cd_r",
"cd_rw", "dvd_rom", dvd_r", "dvd_rw",
"dvd_ram", "dvd_plus_r", "dvd_plus_rw"
(block_class_pre_process): Don't set volume.disc_type, but set the
boolean property volume.is_disc.
* hald/linux/linux_dvd_rw_utils.c (disc_is_appendable): new function
2004-05-09 David Zeuthen <david@fubar.dk>
* hald/linux/linux_dvd_rw_utils.h:
s/get_dvd_media_type/get_disc_type/
* hald/linux/linux_dvd_rw_utils.c (get_dvd_media_type):
s/get_dvd_media_type/get_disc_type/
2004-05-13 Joe Shaw <joe@ximian.com>
* hald/linux/block_class_device.c (detect_media): Connect to the
"callouts_finished" signal and call the callouts rather than
removing the volume from the GDL here. Patch from Sjoerd Simons
<sjoerd@luon.net>
* hald/linux/net_class_device.c (mdio_read): Make the result an
out parameter and return 0 on success and -1 on failure.
(mii_get_rate): Check the result of mdio_read(). Put the check
for whether it's 10mbit in an else-if.
(mii_get_link): Check the result of mdio_read(). Based on a patch
from Sjoerd Simons <sjoerd@luon.net>
2004-05-08 Joe Shaw <joe@ximian.com>
* tools/callouts/fstab-update.sh: Improve the locking loop.
2004-05-07 Joe Shaw <joe@ximian.com>
* NEWS: Update the udev requirements. Patch rom Kay Sievers
<kay.sievers@vrfy.org>
* doc/TODO: Add an item about clean daemon shutdown.
* tools/callouts/fstab-update.sh: Add locking on the fstab so
things don't race for it. Timeout after 10 seconds. Also be
overly cautious about when we remove the block device from the
fstab and check to make sure that the resulting fstab exists and
is larger than 0 bytes in size.
2004-05-05 David Zeuthen <david@fubar.dk>
* hald/linux/linux_dvd_rw_utils.c (get_dvd_media_type): new function
* hald/linux/block_class_device.c: rename some properties and ensure
that all properties for a namespace is always available with default
values - it's easiest to look at the diff to see what's changed; one
highlight is the introduction of the volume.* namespace.
(detect_media): use new utility in linux_dvd_rw_utils.c to get the
disc type for DVD's.
* tools/callouts/fstab-update.sh: property names changed
* fdi/20freedesktop/lexar-media-cf-reader.fdi: propertys name changed
* fdi/20freedesktop/6in1-card-reader.fdi: property names changed
2004-05-05 Kay Sievers <kay.sievers@vrfy.org>
* hald/linux/volume_id/volume_id.c (probe_udf): fix for big-endian
2004-05-04 David Zeuthen <david@fubar.dk>
* hald/linux/volume_id/volume_id.c (probe_jfs): test for js == NULL
* hald/linux/block_class_device.c (detect_media): call detect_fs
when adding a disc. Also route the child through the TDL and test
the TDL so we don't add more than one child now that we've got a
delay thanks to callouts.
(add_to_gdl): rename to disc_add_to_gdl, since we use it only for
optical discs
2004-05-04 Kay Sievers <kay.sievers@vrfy.org>
* hald/linux/volume_id/volume_id.[ch] : support reading of iso9660
and udf labels
2004-05-04 David Zeuthen <david@fubar.dk>
* libhal/libhal.c (hal_ctx_set_user_data): new function
(hal_ctx_get_user_data): new function
2004-05-01 Owen Fraser-Green <owen@discobabe.net>
* hald/hald_dbus.c (manager_find_device_string_match): Set
info.value
2004-05-01 David Zeuthen <david@fubar.dk>
* libhal/libhal.h: fix that the extern "C" linkage stuff was
accidently commented out
2004-05-01 David Zeuthen <david@fubar.dk>
* hald/callout.c (iochn_data): remember to remove element from
active_callouts list
* hald/linux/class_device.c (class_device_detection_done): remove
2004-05-01 David Zeuthen <david@fubar.dk>
* hald/Makefile.am (install-data-local): create /etc/hal/property.d
* tools/callouts/fstab-update.sh: s/msdos/vfat/ if applicable
* hald/logger.h: include stdio.h, stdlib.h since DIE macro uses this
* doc/TODO: removed a TODO-note :-)
* hald/callout.c (wait_for_callout): removed
(handle_sigchld): new function
(iochn_data): new function
(process_callouts): install signal handler and setup GIOChannel
stuff; don't install timeout for waiting for child
* hald/linux/class_device.c (class_device_detection_done): removed
* hald/linux/bus_device.c (bus_device_detection_done): removed
2004-04-30 Joe Shaw <joe@ximian.com>
* hald/linux/block_class_device.c (block_class_pre_process):
Process the mtab here, so that our fstype and mount_point
properties are set.
* hald/linux/bus_device.h, hald/linux/class_device.h: Remove the
detection_done function. It's not really useful with all the
asynchronicity.
* hald/linux/*_bus_device.c, hald/linux/*_class_device.c: Remove
the detection_done functions.
* hald/hald_dbus.c (foreach_device_by_capability): Make sure caps
is not NULL before comparing strings.
2004-04-30 David Zeuthen <david@fubar.dk>
* doc/TODO: update TODO note about fs detection
2004-04-30 Kay Sievers <kay.sievers@vrfy.org>
* hald/Makefile.am (hald_SOURCES): add volume_id/volume_id.[ch]
* hald/linux/block_class_device.c (detect_fs): use utility in new
subdirectory volume_id
* hald/linux/volume_id/volume_id.[ch]: new files
2004-04-27 Joe Shaw <joe@ximian.com>
* doc/TODO: Remove a now completed TODO item.
* hald/hald.c (gdl_store_changed): Don't call hal_callout_device()
in the removed case.
* hald/linux/osspec.c (remove_callouts_finished): Actually remove
the device from the GDL in this callback.
(remove_device, remove_class_device): Connect to the
callouts_finished signal and call device callouts instead of
removing it from the GDL here.
2004-04-26 Joe Shaw <joe@ximian.com>
* hald/callout.c (hal_callout_device): We still need to emit the
callouts_finished signal even if we have no callouts. Whoops.
* hald/bus_device.c (bus_device_got_parent): We don't need to ref
the device being added, since it's no longer unconditionally being
unreffed immediately afterward.
* hald/class_device.c (class_device_final): Ditto.
* hald/common.c (device_move_from_tdl_to_gdl): Remove the ref note
in the comment, and call g_object_ref() at the top of the
function.
2004-04-26 David Zeuthen <david@fubar.dk>
* doc/TODO: Added note about waiting for callouts to complete before
removing a device and waiting for children to disappear before a
device is removed
2004-04-26 David Zeuthen <david@fubar.dk>
* hald/device.c (hal_device_print): Print out to stderr instead of
stdout.
* hald/device_store.c (hal_device_store_print): Print out the
contents of a HalDeviceStore.
* hald/linux/common.c (rename_and_merge): Check to see if the UDI
exists in the TDL and try again if it is.
2004-04-26 Joe Shaw <joe@ximian.com>
* hald/callout.c: Make pending callouts a hash table of lists, so
we can execute all the callouts for the devices in order.
(add_pending_callout, pop_pending_callout): New convenience
functions.
(wait_for_callout): If this is the last callout for a device, fire
off the callouts_finished signal on the device.
(hal_callout_device, hal_callout_capability,
hal_callout_property): Use the new convenience functions, call
process_callouts() in an idle function.
* hald/device.c: Add a "callouts_finished" signal.
* hald/hald.c (gdl_store_changed): Don't call hal_callout_device()
here anymore... we call it in the backend before we get added to
the GDL.
* hald/hald_dbus.c (manager_device_exists,
device_get_all_properties, device_get_property,
device_get_property_type, device_set_property,
device_add_capability, device_remove_property,
device_property_exists, device_query_capability,
agent_merge_properties, agent_device_matches): Search the TDL for
the provided UDI if it's not found in the GDL.
* hald/linux/block_class_device.c (detect_media): Instead of
adding the device to the GDL immediately, connect to the
callouts_finished signal and add the device then. Call
hal_callout_device() here, though.
* hald/linux/bus_device.c (bus_device_got_parent): Ditto.
* hald/linux/class_device.c (class_device_final): Ditto.
* hald/linux/common.c (device_move_from_tdl_to_gdl): Remove the
device from the TDL and add it to the GDL. Remove the signal
handler and unref the device. Used as a callback from
bus_device.c and class_device.c.
2004-04-26 David Zeuthen <david@fubar.dk>
* hald/linux/macio_bus_device.c: new file because with the recent
change in how probing is handled, my CD-ROM wasn't added until 30
seconds late into the process as the macio glue wasn't handled
* hald/Makefile.am (hald_SOURCES): add linux/macio_bus_device.c
* hald/linux/osspec.c: add macio_bus_handler to bus_device_handlers
* tools/device-manager/Const.py.in (BUS_NAMES): Add macio mapping
2004-04-25 David Zeuthen <david@fubar.dk>
* doc/TODO: Add our notes about current issues with the Linux 2.6
kernel
* hald/linux/usbif_bus_device.c (usbif_device_accept): remove
is_probing
* hald/linux/usb_bus_device.c (usb_device_accept): remove is_probing
* hald/linux/printer_class_device.c (printer_class_device_accept):
remove is_probing
* hald/linux/osspec.c (visit_class_device): optionally take and use
a ClassDeviceHandler object
(visit_class): -do-
(visit_device): optionally take and use a BusDeviceHandler object
(visit_bus): new function; not currently used
(osspec_probe): add a comment about migration to visit_bus once the
kernel is ready; slight changes
* hald/linux/net_class_device.c (net_class_pre_process): set category
and capabilities
* hald/linux/ide_host_bus_device.c (ide_host_device_accept): remove
is_probing
* hald/linux/common.c (got_parent): new function
* hald/linux/class_device.h: change prototypes by removing is_probing
parameter
* hald/linux/class_device.c don't pass is_probing; use
hald_is_initialising global instead
* hald/linux/bus_device.h: change prototypes by removing is_probing
parameter
* hald/linux/bus_device.c: don't pass is_probing; use the global
hald_is_initialising instead. Don't try to find parent if the sysfs
path indicates that there is no parent.
* hald/linux/block_class_device.c : don't pass is_probing; use
hald_is_initialising global
2004-04-22 David Zeuthen <david@fubar.dk>
* hald/linux/usb_bus_device.c (usb_add_caps_from_class): don't set
capabilities from device class since this is very misleading.
In fact, capabilities should only stem from kernel- or userspace-
drivers. We retain the right to set the usbhub capability as no
kernel driver is bound to this class of devices. Yet.. who knows?
In either case, a GUI device browsers can always inspect the info.bus
and consult the appropriate stuff, e.g. the usb.device_class,
_sub_class and _protocol deal for usb devices, to select an appropriate
icon.
* hald/linux/pci_bus_device.c (pci_add_caps_from_class): removed for
same reasons as above
(pci_device_pre_process): don't call pci_add_caps_from_class
* tools/device-manager/Representation.py:
s/bridge.cardbus/pcmcia_socket/
* hald/linux/osspec.c: add pcmcia_socket_class_handler
* hald/linux/pcmcia_socket_class_device.c: new file; very simple just
tag a busdevice with the capability pcmcia_socket
* hald/linux/class_device.c (class_device_final): log an informative
message when we merge onto a device
2004-04-22 David Zeuthen <david@fubar.dk>
* hald/linux/class_device.c (class_device_got_sysdevice): Instead
of refusing to merge onto a socalled virtual device (which is really
a HAL term, and thus quite crackful), just special-case the fact
that we don't want to merge onto a usb interface but we prefer to
merge onto the usb device. Which is sane and quite nice.
This makes the scsi_device receive the scsi_generic class stuff and
thus the scsi_generic.device_file=sg0 property. Which is also sane
and quite nice (think SCSI multi-lun devices).
* hald/linux/osspec.c (remove_class_device): Make a more concise
statement in the log message about the fact that removal of class
devices is not yet implemented; add @todo tag so this is not
forgotten
* doc/TODO: Add note about removal of class devices
2004-04-21 Joe Shaw <joe@ximian.com>
* doc/TODO: Add a couple of callout-related items.
* hald/callout.c (process_callouts): Reallocate the envp here with
enough space for all of the properties, since properties were
probably added since we initially measured the space.
(hal_callout_device, hal_callout_capability,
hal_callout_property): Reenable these. Don't bother counting the
number of properties here, it doesn't matter. Instead allocate
just enough space for our special env vars and let
process_callouts() deal with the rest.
2004-04-21 David Zeuthen <david@fubar.dk>
* hald/callout.c
(hal_callout_property): callouts seem to be a bit broken right
now (segfaults my box etc.), so disable them. Hopefully this is
fixed soon!
(hal_callout_capability): -do-
(hal_callout_device): -do
* hald/linux/usbif_bus_device.c (usbif_device_compute_udi): Don't
print details about the device
* hald/linux/usb_bus_device.c (usb_proc_parse): Comment out noisy
print statements
* hald/linux/osspec.c
(handle_udev_node_created_found_device):
(visit_class_device): clean up logging statements
(visit_device): -do-
(remove_device): comment out noisy logging statements
(remove_class_device): -do-
(handle_hotplug): -do-
* hald/linux/class_device.c
(class_device_got_device_file): comment out noisy logging statement
(class_device_accept): -do-
* hald/linux/common.c
(rename_and_merge): comment out noisy logging statements
(class_device_get_device_file): -do-
* hald/hald.c (gdl_store_changed): don't print device, just print
the UDI
2004-04-21 Robert Love <rml@ximian.com>
* hald/callout.c: add property modified callout;
change the action parameter to a tri-state and add appropriate enum
* hald/callout.h: add prototype for hal_property_callout
* hald/hald.c: invoke hal_property_callout on property modification
2004-04-20 David Zeuthen <david@fubar.dk>
* doc/TODO (CVSID): Updated
2004-04-20 Robert Love <rml@ximian.com>
* hald/callout.c: hal_property_get_as_string is now to_string, fix
leak.
* hald/device.c: add hal_device_property_to_string
* hald/device.h: add prototype for hal_device_property_to_string
* hald/property.c: rename hal_property_get_as_string to to_string
* hald/property.h: ditto for the prototype
2004-04-20 Joe Shaw <joe@ximian.com>
* hald/callout.c (Callout): Add the HalDevice to the structure, we
need it for getting the properties. Add the starting index for
the envp.
(add_property_to_env): Deal with Callout structs instead of
ForeachPropInfo.
(process_callouts): Add the properties to the environment here, at
callout time, instead of up front, since callouts may have changed
properties, and we want later callouts to have the most up-to-date
info.
(process_callouts): Change the idle to a timeout. This is a
copout.
2004-04-20 Joe Shaw <joe@ximian.com>
* hald/callout.c: Rework this some to make the callouts
asynchronous and tied in with the main loop, so that callouts can
either link against libhal or use hal-{get|set}-property without
deadlocking.
2004-04-19 Robert Love <rml@ximian.com>
* hald/callout.c (hal_callout_capability): add properties to
environment and set working directory correctly
2004-04-15 Joe Shaw <joe@ximian.com>
* hald/device.c (hal_device_async_wait_property): Ref the device
when we create the AsyncInfo. This should fix the glib warnings
about signals.
(destroy_async_match_info): Unref it when we're finished.
2004-04-14 Joe Shaw <joe@ximian.com>
* hald/Makefile.am: Build the new scsi_generic class handler.
* hald/linux/osspec.c: Add scsi_generic_class_handler. Also add a
comment about how the order of the class_device_handlers array is
important, particularly when probing at startup.
* hald/linux/scsi_generic_class_device.c: Added. The actual
handler. The dumbest and most straightforward backend yet.
* tools/linux/hal_hotplug.c: Add file_list_scsi_generic.
(wait_for_sysfs_info): And add it here...
2004-04-12 Joe Shaw <joe@ximian.com>
* tools/device-manager/DeviceManager.py: Wrap the gnome.ui import
in a try statement and desensitize the About menu item if it
fails. This is to work around a broken python-gnome package on
SUSE 9.0.
2004-04-12 Joe Shaw <joe@ximian.com>
* hald/Makefile.am: Build the new net class device.
* hald/linux/*.c: Change "post_process" to "pre_process", since
we're actually doing all of this before our HalDevice merges into
a superior one or gets added to the GDL.
* hald/linux/class_device.h (ClassDeviceHandler): Add a new
handler, "post_merge", which is called after we merge devices in
class_device_final().
* hald/linux/class_device.c (class_device_final): Call our new
post_merge function after we've merged devices.
* hald/linux/net_class_device.c: Add back in network class device
support. Uses MII registers to get the initial link state and
uses netlink sockets to update it in real-time.
* hald/linux/osspec.c: Add net_class_handler.
2004-04-12 David Zeuthen <david@fubar.dk>
* hald/linux/block_class_device.c (block_class_post_process):
s/hotplugable/hotpluggable/
2004-04-12 David Zeuthen <david@fubar.dk>
* hald/linux/block_class_device.c (block_class_post_process):
Introduce storage.physical_device to point to the physical device
backing this storage device
2004-04-12 David Zeuthen <david@fubar.dk>
* hald/linux/block_class_device.c (block_class_post_process): Merge
storage.* and storage_lun%d.* properties from physical device (eg.
usb, ieee1394, ide) onto storage device
* hald/device.c (hal_device_merge_with_rewrite): new function
* hald/device.h: add prototype for hal_device_merge_with_rewrite
* fdi/20freedesktop/lexar-media-cf-reader.fdi: new file
* fdi/20freedesktop/6in1-card-reader.fdi: new file
* fdi/20freedesktop/Makefile.am: add fdi files for my two card reader
devices
2004-04-12 David Zeuthen <david@fubar.dk>
* hald/linux/block_class_device.c (detect_fs_fat): make data an
unsigned char array
(block_class_post_process): Always choose the block.storage_device
to be the top-level block device. Walk up the device chain to set
storage.bus to [ide|ieee1394|usb] as appropriate.
2004-04-11 David Zeuthen <david@fubar.dk>
* hald/linux/osspec.c
(visit_class_device): Don't die if sysfs path is invalid
(visit_device): Don't die if sysfs path is invalid
2004-04-11 David Zeuthen <david@fubar.dk>
* tools/callouts/fstab-update.sh: Yuck, append a nondigit to
MOUNTPOINT otherwise the removal of disk-8-1 (sda1) will also remove
disk-8-17 (sdb1)
2004-04-11 David Zeuthen <david@fubar.dk>
* tools/callouts/fstab-update.sh: Use HAL_PROP_BLOCK_FSTYPE if
available
* hald/linux/block_class_device.c (block_class_post_process): Move
check for storage.is_hotplugable
(block_class_post_process): Call detect_fs() to detect volume name
(detect_fs_fat): new function, sets block.fstype to vfat and
block.volume_label for volumes with FAT filesystems
(detect_fs): new function
2004-04-10 David Zeuthen <david@fubar.dk>
* libhal/libhal.[ch]: Added LibHalContext object so a stack of
libraries and applications can simultaneously use libhal
* libhal/libhal.h : Added LibHalLostCapability
* libhal/libhal.c (hal_device_get_all_properties): Fixed a bug where
the last property was missing
* tools/hal_get_property.c: update to new libhal API
* tools/hal_set_property.c: Update to new libhal API
* tools/lshal.c: Update to new libhal API
2004-04-10 David Zeuthen <david@fubar.dk>
* hald/linux/block_class_device.c (block_class_post_process):
Revert to setting the storage backing device to the top-level
block device
2004-04-10 David Zeuthen <david@fubar.dk>
* hald/linux/class_device.h: add got_udi() method
* hald/linux/class_device.c (class_device_final): move add/merge of
class device to a single function
* hald/linux/bus_device.h: add got_udi() method
* hald/linux/bus_device.c (bus_device_got_parent): call got_udi()
before adding
(bus_device_got_udi): new function
* hald/linux/block_class_device.c (block_class_got_udi): new function
(block_class_post_process): set block.storage_device to the physical
device, e.g. USB etc., backing the block device; simplify a bit
2004-04-08 Joe Shaw <joe@ximian.com>
* hald/linux/printer_class_device.c (printer_class_device_accept):
Added. Only accept class devices which have a name of "lpN".
(printer_class_post_process): Get a description from the IEEE-1284
output and put it in printer.description.
(printer_class_handler): Set the accept function to be
printer_class_device_accept(), and change the sysfs class name
from "printer" back to "usb".
* tools/callouts/fstab-update.sh: Add some introductory text to
the top of it, including a big warning. Create the mountpoint
with mkdir -p instead of each individual directory.
2004-04-08 David Zeuthen <david@fubar.dk>
* tools/callouts/fstab-update.sh: Callout script for fstab management
2004-04-08 David Zeuthen <david@fubar.dk>
* hald/linux/osspec.c (remove_device): new function
(remove_class_device): new function
(handle_hotplug): simplify
2004-04-07 David Zeuthen <david@fubar.dk>
* tools/linux/hal_dev.c: New file for sending device event
* tools/linux/Makefile.am: Build and install hal.dev
* hald/linux/class_device.h: Add accept method to ClassDeviceHandler
* hald/Makefile.am (install-data-local): Create /etc/hal/device.d and
/etc/hal/capability.d
* hald/linux/osspec.c (handle_device_event): new function
(handle_udev_node_created): removed function
(osspec_filter_function): Handle events from hal.dev so we don't
need to rely on udev having built-in dbus support
* configure.in: Bump version to 0.2.90
2004-04-05 Joe Shaw <joe@ximian.com>
* hald/linux/printer_class_device.c: Added. New printer class.
* hald/linux/Makefile.am: Build linux/printer_class_device.c
* hald/linux/osspec.c: Add the printer class handler.
2004-04-03 David Zeuthen <david@fubar.dk>
* hald/main.c : Removed file
* hald/linux/: Remove files from old backend
2004-04-03 David Zeuthen <david@fubar.dk>
Merge hal-gobject-branch back to HEAD
2004-04-03 David Zeuthen <david@fubar.dk>
* hald/linux/bus_device.c: Various cleanups
* hald/linux/class_device.c: Various cleanups
* hald/linux/block_class_device.c: Various cleanups
* hald/device.c (hal_device_async_wait_property): New method
2004-04-02 David Zeuthen <david@fubar.dk>
* hald/linux/osspec.c (handle_hotplug): Actually remove class devices
that populate the tree
(handle_udev_node_created): Search in Temporary Device List instead of
the Global Device List - quite important difference :-)
* hald/linux/common.c (rename_and_merge): remove from tdl
* hald/linux/class_device.c (class_device_visit): add to tdl
(class_device_got_parent_device): remove from tdl
(class_device_got_sysdevice): remove from tdl
(class_device_got_device_file): remove from tdl
* hald/linux/bus_device.c (bus_device_visit): Asynchronously find
the parent device instead of synchronously
(bus_device_got_parent): New format
* hald/linux/block_class_device.c (block_class_visit): add to tdl
(detect_media): Add the patch from rml for storage.cdrom.media_type
(block_class_removed): new function
* hald/hald.c (hald_get_tdl): New function to get temporary device
list
2004-04-01 David Zeuthen <david@fubar.dk>
* hald/linux/common.c (rename_and_merge): Fixed a subtle error where
multiple instances of the same device couldn't appear in the device
list
2004-03-29 Robert Love <rml@ximian.com>
* tools/linux/hal_hotplug.c: add a "strcat_len()" macro and use it
2004-03-29 Robert Love <rml@ximian.com>
* tools/linux/hal_hotplug.c: sysfs_mnt_path should be a "char []"
not a "char * []", also use PATH_MAX instead of 255, and finally
use "const char" as appropriate
2004-03-30 David Zeuthen <david@fubar.dk>
* hald/linux/block_class_device.c (detect_media): media detection
on CD-ROM's from the patch from Robert (storage.cdrom.media_type)
(block_class_tick): Comment out noisy debug statement when polling
2004-03-30 David Zeuthen <david@fubar.dk>
* hald/main.c (device_get_all_properties): Comment out noise trace
call
* hald/device_store.c
(ds_device_merge, ds_add_capability): Signal capability added even
though target device already had the capability. Fixes problem with
monitoring ethernet devices.
2004-03-28 David Zeuthen <david@fubar.dk>
* hald/linux/linux_class_block.c (visit_class_device_block): Remove
block.[size|start|block_size] properties
2004-03-26 Robert Love <rml@ximian.com>
* hald/linux/linux_class_block.c (media_detect_timer_handler): Comment
out noise debug statement
2004-03-25 Robert Love <rml@ximian.com>
* hald/linux/linux_class_block.c (detect_media): add support for
"storage.cdrom.media_type"
2004-03-14 Martin Waitz <tali@admingilde.org>
* hald/linux/linux_usb.c (usb_proc_parse): Just ignore if we can't
open /proc/bus/usb/devices
* hald/linux/usb_bus_device.c (usb_proc_parse): Just ignore if we
can't open /proc/bus/usb/devices
* tools/device-manager/DeviceManager.py: Print out nice error if hald
is not running
2004-03-14 David Zeuthen <david@fubar.dk>
* doc/TODO: Updated TODO file
2004-03-14 David Zeuthen <david@fubar.dk>
Added first stab of rewrite of linux specific parts - the new
code is a lot more object oriented and thus more compact; it's
currently disabled until it's more tested; you have to manually
enable by editing hald/Makefile.am
* hald/Makefile.am (hald_SOURCES): Add new linux specific parts;
currently disabled
* hald/device_store.h: add ds_device_async_wait_for_property()
* hald/device_store.c (DSDeviceAsyncFindStruct): Add device member
used in for wait_for_property
(async_find_check_new_addition): add wait_for_property check
(ds_device_async_wait_for_property): new function
* osspec.c : new file
* common.[ch] : new files
* bus_device.[ch] : new files
* usb_bus_device.c : new file
* usbif_bus_device.c : new file
* pci_bus_device.c : new file
* ide_bus_device.c : new file
* ide_host_bus_device.c : new file
* class_device.[ch] : new files
* input_class_device.c : new file
* block_class_device.c : new file
* scsi_host_class_device.c : new file
* scsi_device_class_device.c : new file
2004-03-05 Sjoerd Simons <sjoerd@air.luon.net>
* hald/linux/linux_class_v4l.c (visit_class_device_v4l): Remove
invalid free of a static string
* hald/linux/linux_common.c (udevinfo_path): Add /usr/bin/udevinfo
as candidate for location of udevinfo
2004-03-03 David Zeuthen <david@fubar.dk>
Major reformatting patch - seems that everyone is following
another coding style than me so I chose the GNOME coding guidelines,
indent -kr -i8 -pcs -lps -psl, and did some manual reformatting
2004-03-01 Joe Shaw <joe@ximian.com>
* configure.in: SUSE puts pci.ids in /usr/share, so add that to
the list of directories to check.
* tools/Makefile.am: Use @PACKAGE_LIBS@ and @DBUS_LIBS@ instead of
referencing the libs directly. This allows us to have dbus and/or
glib in a prefix.
2004-03-01 David Zeuthen <david@fubar.dk>
Preliminary support for waiting for sysfs information to appear -
not complete but it's a start...
* tools/linux/hal_hotplug.c
(get_sysfs_mnt_path): new function
(main): call wait_for_sysfs_info() on hotplug add
(wait_for_sysfs_info): new function
2004-03-01 Sjoerd Simons <sjoerd@air.luon.net>
* hald/linux/linux_common.c (udevinfo_path): new function
* hald/linux/linux_common.h: add udevinfo_path prototype
* hald/linux/linux_class_v4l.c (visit_class_device_v4l): use
udevinfo_path() to get path to udevinfo
* hald/linux/linux_class_block.c
(visit_class_device_block_got_parent): use udevinfo_path() to get
path to udevinfo. Add support for SCSI tape detection. Set correct
storage.media on SCSI CD-ROM and disk detection
2004-02-29 David Zeuthen <david@fubar.dk>
* hald/linux/linux_usb.c (visit_device_usb): New way to check if
device is an interface
2004-02-27 Joe Shaw <joe@ximian.com>
* hald/linux/linux_class_block.c
(visit_class_device_block_got_parent): Handle block devices which
have a "scsi_device" as its parent class. Use sysfs to get
vendor, product, and SCSI device type, which get mapped to HAL
capabilities.
* hald/linux/linux_usb.c (usb_proc_parse): Fallback to
/proc/bus/usb/devices_please-use-sysfs-instead. Yeah, yeah.
2004-01-20 David Zeuthen <david@fubar.dk>
* hald/linux/linux_osspec.c (visit_device): disable ieee1394
(osspec_init): disable ieee1394
(osspec_probe): disable ieee1394
(handle_hotplug): disable ieee1394
2004-01-19 David Zeuthen <david@fubar.dk>
* configure.in: bump version to 0.2.6
* packaging/fedora/hal.spec (Version): bump to 0.2.6
* hald/linux/linux_class_v4l.c (get_udev_root): removed
(linux_class_v4l_init): don't call get_udev_root()
(visit_class_device_v4l): use new options in udev-013
* hald/linux/linux_class_block.c (get_udev_root): removed
(linux_class_block_init): don't call get_udev_root()
(visit_class_device_block_got_parent): use new options in udev-013
2004-01-19 David Zeuthen <david@fubar.dk>
* hald/linux/linux_common.c (drivers_collect): Don't call DIE() if
we cannot open the /sys/bus/<busname>/drivers directory - just
ignore this error with HAL_WARNING()
2004-01-18 David Zeuthen <david@fubar.dk>
* hald/device_store.c (ds_device_merge): treat info.properties in
a special way such that capabilities entries are actually merged
* hald/linux/linux_class_v4l.c (visit_class_device_v4l): Replaced
parent with sysdevice, since that is what we really search for;
split properties onto v4l.[vbi,video,radio]
(visit_class_device_v4l_got_parent): renamed to _got_sysdevice. Merge
information onto sysdevice instead of creating a new device
2004-01-18 Bastien Nocera <hadess@hadess.net>
* hald/linux/linux_dvd_rw_utils.c (get_read_write_speed): fixed bug
where the two write_speed assignments was swapped
* doc/TODO: remove note about ide-scsi and ide-cd
2004-01-17 David Zeuthen <david@fubar.dk>
* doc/TODO: some shuffling around, added note about that
hald/linux/linux_dvd_rw_utils.c is ide-scsi centric
2004-01-17 Bastien Nocera <hadess@hadess.net>
* hald/linux/linux_dvd_rw_utils.c (pull_page2a_from_fd): new function
(get_read_write_speed): new function
* hald/linux/linux_dvd_rw_utils.h: add get_read_write_speed() prototype
* hald/linux/linux_class_block.c
(linux_class_block_check_if_ready_to_add): call get_read_write_speed
for optical drives
2004-01-17 David Zeuthen <david@fubar.dk>
* hald/device_store.c (ds_query_capability): use strtok_r instead
of strstr as it didn't really work (example: will return true if
called with 'cdrom' and caps were 'cdrom.cdr block'.
(ds_add_capability): only announce new capability if we actually
added it
2004-01-17 Joe Shaw <joe@ximian.com>
* hald/Makefile.am (hald_SOURCES): add linux_ieee1394.[ch]
* hald/linux/linux_ieee1394.[ch]: new files
* hald/linux/linux_osspec.c (visit_device): visit IEEE1394 devices
(osspec_probe): handle IEEE1394 devices
(handle_hotplug): handle IEEE1394 devices
2004-01-17 Matthew Mastracci <matt@acclaro.com>
* tools/device-manager/Const.py.in (BUS_NAMES): add video4linux,
fix I2C capitalization
* hald/linux/linux_osspec.c (visit_class_device): add support
for video4linux, minor I2C fixes
(visit_class_device): add support for video4linux
(visit_class_device): use class device path for I2C
(handle_hotplug): hotplug support for video4linux
* hald/Makefile.am (hald_SOURCES): Add linux_class_video4linux.[ch]
* hald/linux/linux_class_video4linux.[ch]: new files
2004-01-17 Bastien Nocera <hadess@hadess.net>
* hald/Makefile.am (hald_SOURCES): Add linux_dvd_rw_utils.[ch]
* hald/linux/linux_class_block.c
(linux_class_block_check_if_ready_to_add): Check for DVD writer
capabilities
* hal.pc.in: Fixup up so applications only need to include libhal and
not dbus
* hald/linux/linux_dvd_rw_utils.[ch]: new files
2004-01-17 Robert Love <rml@ximian.com>
* libhal/libhal.h: Change protototype of foo() to foo(void) to avoid
warnings when compiling -Wstrict-prototypes
2004-01-16 David Zeuthen <david@fubar.dk>
* packaging/fedora/hal.spec (Version): bump version to 0.2.5
* configure.in: bump version to 0.2.5
* tools/linux/hal_hotplug.c (main): sleep 1000ms instead of 500ms
before sending signal - we really need to update to latest libsysfs
in hald to avoid the race - this is soo ugly
* hald/main.c (property_atomic_update_end): fix possible memory
violation
* hald/linux/linux_osspec.c (handle_hotplug): call
linux_class_block_removed() just before destroying the HalDevice obj
* hald/linux/linux_class_block.c (linux_class_block_removed): new
function
* hald/linux/linux_class_block.h: add prototype for
linux_class_block_removed()
* hald/device_store.c
(ds_device_find_multiple_by_key_value_string): new funtion
* hald/device_store.h: add prototype for
ds_device_find_multiple_by_key_value_string()
* hald/linux/linux_class_block.c (sigio_handler): Make this signal
handler *a lot* safer by only setting a flag a timer can pick up
(detect_media): properly handle situation when user removes media
where partitions are mounted on
(media_detect_timer_handler): check sigio_etc_changed
(force_unmount_of_all_childs): newfunction
(force_unmount): new function
(linux_class_block_removed): new function
2004-01-14 David Zeuthen <david@fubar.dk>
* hald/linux/linux_class_block.c (detect_media): Doh, leaked a
filedescriptor which is big trouble. Fixed
2004-01-13 David Zeuthen <david@fubar.dk>
* configure.in: Bump version number to 0.2.4
* packaging/fedora/hal.spec (Release): Bump version number to 0.2.4
* tools/device-manager/hal-device-manager: Remove requirement for
pygtk 2.0 since it broke some systems
2004-01-13 David Zeuthen <david@fubar.dk>
* hald/linux/linux_class_block.c
(linux_class_block_check_if_ready_to_add): ioctl rc>=0 is also success
(detect_media): rewrite most of this function
(visit_class_device_block_got_parent): Rename
storage.has_removable_media to storage.support_removable_media. Set
it for all devices - only properly detected for IDE CD-ROM drives
currently.
(linux_class_block_check_if_ready_to_add): Move storage.* properties
to visit_class_device_block_got_parent()
2004-01-13 David Zeuthen <david@fubar.dk>
* configure.in: Bump version number to 0.2.3
* tools/device-manager/DeviceManager.py
(DeviceManager.device_changed): Add support for Condition signal
* tools/lshal.c (device_condition): new function
(main): add device_condition to LibHalFunctions variable
* libhal/libhal.c (filter_func): Process DeviceCondition
* libhal/libhal.h (LibHalFunctions_s): Add device_condition
and type LibHalDeviceCondition
* hald/linux/linux_class_net.c (link_detection_process): Emit
NetLinkEvent(bool got_link) condition
* hald/linux/linux_class_block.c
(etc_mtab_process_all_block_devices): emit BlockMount(string device,
string mount_point, string fstype) and BlockUnmount(string device)
events
* hald/hald.h: added emit_condition()
* hald/main.c (emit_condition): new function
2004-01-13 Matthew Mastracci <matt@aclaro.com>
* tools/device-manager/Const.py.in (BUS_NAMES): add i2c_adapter
* hald/linux/linux_osspec.c (visit_class_device): add support for
i2c-adapter
(visit_device): add support for i2c and i2c-adapter
(handle_hotplug): hotplug support for i2c and i2c-adapter
* hald/Makefile.am (hald_SOURCES): Add linux_class_i2c_adapter.[ch]
* hald/linux/linux_class_i2c_adapter.[ch]: new files
2004-01-12 David Zeuthen <david@fubar.dk>
* hald/linux/linux_class_block.c
(linux_class_block_check_if_ready_to_add): Check whether optical
drive supports media changed signals
(etc_mtab_process_all_block_devices): Only merge information from
/etc/mtab if block.is_volume==TRUE
(detect_media): New function
(media_detect_timer_handler): New function
(linux_class_block_detection_done): Setup 2 sec timer for media
detection
2004-01-10 David Zeuthen <david@fubar.dk>
* tools/device-manager/hal-device-manager: add requirement for
pygtk version 2.0
2004-01-10 David Zeuthen <david@fubar.dk>
* tools/device-manager/Const.py.in (BUS_NAMES): Add support for i2c
devices
* hald/linux/linux_i2c.[ch]: New files by Matthew Mastracci; slight
modifications by me
* hald/linux/linux_osspec.c (visit_device): Call visit_device_i2c()
* hald/Makefile.am (hald_SOURCES): Add linux_i2c.[ch]
2004-01-08 David Zeuthen <david@fubar.dk>
* hald/linux/linux_class_scsi.c
(visit_class_device_scsi_host): Set scsi_host.host
(visit_class_device_scsi_device): Set scsi_device.[host,bus,target,lun]
(scsi_host_compute_udi): Simplify UDI computation using only
scsi_host.host. This also makes it correct for multi-lun devices
(scsi_device_compute_udi): Simplify UDI computation using the tupple
{host, bus, target, lun}. This also makes it work with multi-lun
devices
* hald/linux/linux_class_block.c
(linux_class_block_check_if_ready_to_add): Add O_NONBLOCK so
optical drive capability query works without a disc mounted.
Add capabilities (e.g. storage.cdr) as always present properties
as well. A bit redundant, but it makes is more easy obvious that
some devices might support this property.
Populate block.storage_device to point the device with the
storage.* properties
2004-01-05 David Zeuthen <david@fubar.dk>
* hald/linux/linux_osspec.c (handle_hotplug): add some more debug
* hald/linux/linux_class_block.c
(visit_class_device_block_got_parent): add some more debug
2004-01-04 David Zeuthen <david@fubar.dk>
* tools/linux/hal_hotplug.c: Don't include dbus-glib
2004-01-04 Joe Shaw <joe@ximian.com>
* hald/main.c (PendingUpdate_s): Remove the "const" from the
"key" field, since it's supposed to be freed.
* hald/linux/linux_class_block.c: #include <glib.h>.
(visit_class_device_block_got_parent): The path should be declared
const. g_spawn_sync() was missing a NULL GError argument.
(etc_mtab_process_all_block_devices): existing_block_device should
be declared const.
(get_udev_root): g_spawn_sync() needs a GError argument.
* hald/linux/linux_class_net.c: Add #include "../hald.h".
(visit_class_device_net): Wrap the check for ARPHRD_IEEE1394 in an
#ifdef, since my machine doesn't seem to define it.
* hald/linux/linux_common.c: #define _GNU_SOURCE since we're using
strndup().
2004-01-04 Joe Shaw <joe@ximian.com>
* configure.in: Do a separate check for dbus alone, so that we can
link libhal to it and not the glib libs. This fixes things for
a dbus installed into a separate prefix.
* libhal/Makefile.am: Use the DBUS_CFLAGS for the INCLUDES and
DBUS_LIBS for the libhal_la_LIBADD.
* tools/linux/Makefile.am: Ditto for hal_hotplug
2004-01-04 Anders Carlsson <andersca@gnome.org>
* tools/device-manager/DeviceManager.py:
Add a couple of code paths for setting vendor.
* tools/device-manager/hal-device-manager.glade:
Fixup to use GtkTable instead of GtkFixed.
2004-01-04 David Zeuthen <david@fubar.dk>
* hald/linux/linux_class_block.c
(linux_class_block_check_if_ready_to_add): moved cdrom cap check to
here. Renamed capabilities from cdrom.* to storage.*
(visit_class_device_block_got_parent): moved cdrom cap away from here
since on hotplugging we are not sure to have block.device.
2004-01-04 Anders Carlsson <andersca@gnome.org>
* hald/linux/linux_class_block.c:
(visit_class_device_block_got_parent):
Add support for cdrom capabilities.
2004-01-04 David Zeuthen <david@fubar.dk>
* fdi/Makefile.am: install fdi.rng
* fdi/fdi.rng: new file (thanks to Dave Malcolm)
2004-01-03 David Zeuthen <david@fubar.dk>
* hald/linux/linux_class_block.c
(visit_class_device_block_got_parent): Invoke udev on hald boot time
to get device file names
(etc_mtab_process_all_block_devices): Be careful not to overwrite
existing block.device when looking at /etc/mtab
(get_udev_root): new function
(linux_class_block_init): find udev root using '/sbin/udev -r'
2004-01-02 David Zeuthen <david@fubar.dk>
* configure.in: bump version to 0.2.2
* hald/linux/linux_class_net.c (link_detection_process): Group
net.ethernet.link and net.ethernet.rate as an atomic update
* fdi/Makefile.am: install fdi.dtd to $(datadir)/hal/fdi
* fdi/fdi.dtd: new file (thanks to Dave Malcolm)
* hald/device_store.c (ds_device_find_by_key_value_string): set
that we can choose whether to search the GDL or not
(ds_device_async_find_by_key_value_string): set that we can choose
whether to search the GDL or not
(ds_device_merge): Do all the merge as an atomic operation
* hald/linux/linux_osspec.c
(handle_udev_node_created_found_device): Call
linux_class_block_check_if_ready_to_add()
(handle_udev_node_created): search for device not in GDL
* hald/linux/linux_common.c (rename_and_merge): renamed from
rename_and_maybe_add. News is that you need to call ds_gdl_add()
explicitly
* hald/linux/linux_*.c: call rename_and_merge() instead. Explicitly
call ds_gdl_add()
* hald/linux/linux_class_block.c
(etc_mtab_process_all_block_devices): make sure we always set required
properties; set all properties in a single transaction
(read_etc_mtab): add force parameter
(etc_mtab_process_all_block_devices): add force parameter
(visit_class_device_block_got_parent): reload /etc/mtab on every
hotplug. Call linux_class_block_check_if_ready_to_add() instead of
ds_gdl_add()
(linux_class_block_check_if_ready_to_add): new function
* libhal/libhal.c (filter_func): Added PropertyModified, removed
Property[Changed, Added, Removed]
* libhal/libhal.h (LibHalFunctions_s): Added PropertyModified, removed
Property[Changed, Added, Removed]
* tools/device-manager/DeviceManager.py
(DeviceManager.device_changed): Listen for PropertyModified instead.
Print out payload on stdout for debugging purposes
* tools/lshal.c (property_modified): new function
(property_added): removed
(property_removed): removed
(property_changed): removed
* hald/main.c (hald_atomic_update_begin): new function
(hald_atomic_update_end): new function
(property_changed): add support for atomic updates
(main): Run as root, we require this to sniff mii registres
* hal.conf.in: Run as root, we require this to sniff mii registres
* hald/hald.h: new file
2003-12-30 David Zeuthen <david@fubar.dk>
* configure.in: Change default user to from hal to haldaemon since
people may already use login called hal or hald (I know of both).
Bump version number to 0.2.1
* packaging/fedora/hal.spec: new file
* hald/main.c (main): Use HAL_USER macro instead of the hardcoded hal
* hal.conf.in: group policy segfaults dbus-daemon-1 on 0.20, but works
in CVS; Now changed so only root can use the AgentManager interface
2003-12-29 David Zeuthen <david@fubar.dk>
* configure.in: add --with-init-scripts and --with-pid-file. Now
configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
works like a charm on Fedora Core 1.
* hald/Makefile.am: handle initscripts fun
* hald/haldaemon.in: new file
2003-12-29 David Zeuthen <david@fubar.dk>
* Makefile.am: add hal.conf.in to EXTRA_DIST to so make distcheck
passes
* configure.in: add --with-hal-user and --with-hal-group, defaults
to hal:hal. Autogenerate hal.conf
* hal.conf.in: new file
* hal.conf: remove, since it is now autogenerated
* hald/Makefile.am: Add $(sysconfig) dir
* hald/main.c (usage): new function
(main): Add commandline parsing, daemonizing and run-as-user
* hald/linux/linux_usb.c (visit_device_usb_got_parent): fix a stupid
bug where proc info wasn't reloaded
(usb_proc_parse): Set cur info to NULL on subsequent calls to make
it work
2003-12-23 David Zeuthen <david@fubar.dk>
* configure.in: add autogeneration doc/Makefile, examples/Makefile and
examples/volumed/Makefile
* Makefile.am: add doc and examples to SUBDIRS
* examples/Makefile.am: new file
* examples/volumed/Makefile.am: new file
* doc/Makefile.am: new file
* doc/TODO: updated
* HACKING: updated
* NEWS: updated, since 0.2 is ready for distribution
2003-12-23 David Zeuthen <david@fubar.dk>
* doc/TODO: updated
2003-12-23 David Zeuthen <david@fubar.dk>
* configure.in: Drop DEVICEMANAGER_DIR. This allows us to do make
install even in maintainer mode, but changes to datafiles (glade
and png's) needs to be installed every time unless Const.py is
directly edited. Add autogeneration of fdi/Makefile and
fdi/10generic/Makefile and fdi/20freedesktop/Makefile.
* hald/device_info.c (handle_match): Fix check for merge of the
other non-string types (bool, int, double)
(end): Merge non-string types
* hald/linux/linux_class_block.c
(visit_class_device_block_got_parent): rename various properties
to match the spec.
* hald/linux/linux_class_input.c (process_input_proc_info): rename
various properties to match the spec.
* hald/linux/linux_common.c (rename_and_maybe_add): Implement
merging with persistent unplugged devices; search for .fdi files
* hald/linux/linux_osspec.c (handle_hotplug): Don't destroy
persistent devices on remove; rather mark the unplugged,
info.not_available set to true, and remove some key properties in
info and linux namespace.
* hald/linux/linux_usb.c (usb_add_caps_from_class): Renamed capability
from storage to storage_controller to match spec.. Hmm.. not sure..
* tools/device-manager/Const.py.in: Use @DATADIR@ and path instead
of @DEVICEMANAGER_DIR@
* tools/device-manager/Representation.py: Add support for capability
camera and fixup how the storage icon is selected to reflect the new
spec
* fdi/Makefile.am: new file
* fdi/10generic/Makefile.am: new file
* fdi/10generic/usb-classes.fdi: removed
* fdi/20freedesktop/Makefile.am: new file
* fdi/20freedesktop/ibm-usb-hub-keyboard.fdi: removed
* fdi/20freedesktop/lexar-cf-card-reader.fdi: removed
* fdi/20freedesktop/canon-digital-ixus-v.fdi: new file
2003-12-22 David Zeuthen <david@fubar.dk>
* libhal/libhal.c (hal_free_string): rename from hal_free_utf8 as
this name makes more sense and we don't yet support utf8 strings
(hal_device_get_all_properties): fix memory leak of dbus strings in
multiple places. Note: we have to audit hald as well :-/
(filter_func): fix dbus string memory leakages
(hal_initialize): add use_cache to preserve API compatilibility when
we actually get around to implement caching in libhal
(hal_get_all_devices): add check for oom
(hal_device_get_property_type): fix dbus string memory leakages
* libhal/libhal.h: change hal_initialize() prototype. Change name
of hal_free_utf8() to hal_free_string()
* tools/Makefile.am: rename hal_[s|g]et_property program to
hal-[s|g]et-property.
* tools/hal_get_property.c (main): call hal_initialize with correct
number of arguments. Fix string leakage bug.
* tools/hal_set_property.c (main): call hal_initialize with correct
number of arguments
* tools/lshal.c (dump_devices): Call hal_free_string_array() instead
of dbus_free_string_array()
(print_property): fix string leakage
(main): call hal_initialize with correct number of arguments
2003-12-22 David Zeuthen <david@fubar.dk>
* acinclude.m4: borrow AS_AC_EXPAND from gstreamer (Martin Waitz)
* configure.in: use AS_AC_EXPAND and define $(LN_S) and request
generation of tools/device-manager/Const.py (Martin Waitz)
* hald/Makefile.am: add $(top_srcdir) to pass make distcheck (Martin
Waitz)
* tools/Makefile.am: add $(top_srcdir) to pass make distcheck, and
use direct path to libhal (Martin Waitz)
* tools/device-manager/Const.py.in: use autoconf vars (Martin Waitz)
* tools/device-manager/Makefile.am: simplify by removing manual
variable replacement and by using dist_ and nodist_ prefixes. Use
$(LN_S) to link (Martin Waitz)
* tools/linux/Makefile.am: Fix symlinking (Martin Waitz)
2003-12-22 David Zeuthen <david@fubar.dk>
* tools/device-manager/*: Some changes due to the big rename patch
* hald/*.c: The big property rename change patch
s/Bus/info.bus/
s/Capabilities/info.capabilities/
s/Category/info.category/
s/Product/info.product/
s/Vendor/info.vendor/
s/Linux.sysfs_path/linux.sysfs_path/
s/Linux.sysfs_path_device/linux.sysfs_path_device/
s/Linux.sysfs_bus_id/linux.sysfs_bus_id/
s/Parent/info.parent/
s/PhysicalDevice/info.physical_device/
info.udi NEW
s/pci.Product/pci.product/
s/pci.Vendor/pci.vendor/
s/pci.ProductSubSystem/pci.subsys_product/
s/pci.VendorSubSystem/pci.subsys_vendor/
s/pci.deviceClass/pci.device_class/
s/pci.deviceSubClass/pci.device_subclass/
s/pci.deviceProtocol/pci.device_protocol/
s/pci.idProduct/pci.product_id/
s/pci.idVendor/pci.vendor_id/
s/pci.idProductSubSystem/pci.subsys_product_id/
s/pci.idVendorSubSystem/pci.subsys_vendor_id/
s/usb.Product/usb.product/
s/usb.Vendor/usb.vendor/
s/usb.bDeviceClass/usb.device_class/
s/usb.bDeviceSubClass/usb.device_subclass/
s/usb.bDeviceProtocol/usb.device_protocol/
s/usb.bMaxPower/usb.max_power/
s/usb.bcdDevice/usb.device_revision_bcd/
s/usb.bcdSpeed/usb.speed_bcd/
s/usb.bcdVersion/usb.version_bcd/
s/usb.busNumber/usb.bus_number/
s/usb.canWakeUp/usb.can_wake_up/
s/usb.configurationValue/usb.configuration_value/
s/usb.idProduct/usb.product_id/
s/usb.idVendor/usb.vendor_id/
s/usb.levelNumber/usb.level_number/
s/usb.numConfigurations/usb.num_configurations/
s/usb.numInterfaces/usb.num_interfaces/
s/usb.numPorts/usb.num_ports/
s/usb.selfPowered/usb.is_self_powered/
s/usb.serial/usb.serial/
s/usbif.bInterfaceClass/usbif.interface_class/
s/usbif.bInterfaceSubClass/usbif.interface_subclass/
s/usbif.bInterfaceProtocol/usbif.interface_protocol/
s/usbif.deviceIdProduct/usbif.device_product_id/
s/usbif.deviceIdVendor/usbif.device_vendor_id/
s/ide.channel/ide.channel/
s/ide.channel/ide.sub_channel/
s/ide_host.number/ide_host.number/
s/block.device/block.device/
s/block.fileSystem/block.fstype/
s/block.isMounted/block.is_mounted/
s/block.isVolume/block.is_volume/
s/block.major/block.major/
s/block.minor/block.minor/
s/block.mountPoint/block.mount_point/
s/block.size/block.size/
s/block.start/block.start/
s/block.model/block.model/
s/block.media/block.media/
s/block.removableMedia/block.has_removable_media/
block.block_size NEW
s/net.ethernet.macAddr/net.ethernet.mac_addr/
s/net.ethernet.macAddrLower24/net.ethernet.mac_addr_lower24/
s/net.ethernet.macAddrUpper24/net.ethernet.mac_addr_upper24/
s/net.arpProtoHwId/net.arp_proto_hw_id/
2003-12-22 David Zeuthen <david@fubar.dk>
* hald/linux/linux_usb.c (usb_proc_parse): Allow multiple invocations,
specifically one on every hotplug :-)
(visit_device_usb_got_parent): Call usb_proc_parse, so we get up-to-
date information from proc
2003-12-22 David Zeuthen <david@fubar.dk>
* hald/device_store.c (async_find_check_new_addition): fixed a
quite subtle bug where multiple finds for the same device were
out there. I just love bloody callbacks :-/
2003-12-21 David Zeuthen <david@fubar.dk>
* examples/volumed/volumed.py: be less verbose
* hald/linux/linux_osspec (osspec_init): Add match for udev signals
(osspec_hotplug): renamed to handle_hotplug since old name didn't make
any sense
(handle_udev_node_created): new function
(handle_udev_node_created_found_device): new function
(osspec_filter_function): add check for udev signals
* tools/linux/hal_hotplug.c (main): sleep a while so the kernel has
time to populate sysfs (hmmm)
2003-12-21 David Zeuthen <david@fubar.dk>
* Doxyfile.in: add tools directory
* hald/device_store.c: fixup doxygen grouping
* hald/device_store.h: fixup doxygen grouping
* hald/logger.c: Don't print out trace priority logging statements
* hald/linux/linux_class_block.c: Add mount point detection by
monitoring /etc and looking at /etc/mtab. Several new functions.
* hald/linux/linux_class_input.c
(linux_class_input_handle_hotplug_add): new function
* hald/linux/linux*.[ch]: Add _detection_done() method that is called
when device detection (on startup of the HAL daemon) is done
* hald/linux/linux_osspec.c (osspec_init): Call _detection_done
(ospec_hotplug): Handle input being hotplugged
* tools/hal_get_property.c: added doxygen comments
* tools/hal_set_property.c: added doxygen comments
* tools/lshal.c: added doxygen comments
2003-12-21 David Zeuthen <david@fubar.dk>
* hald/device_store.c (ds_device_destroy): Only call gdl_changed_cb's
if the device being destructed is in the GDL
* hald/main.c (raise_wrong_state): removed
(device_enable): removed
(device_disable): removed
(filter_function): remove call to device_enable() and device_disable()
(gdl_changed): fix really silly bug where added and removed signals
were switched
* hald/linux/linux_common.c (rename_and_maybe_add): since we don't
know anything about states, disable functionality for unplugged
persistent devices
* hald/linux/linux_usb.c (visit_device_usb): fixed segfault bug
where kernel didn't gave neither vendor nor product name (thanks
to testing on my powerbook that now finally runs 2.6.0, Yay!)
* libhal/libhal.c (hal_device_disable): removed
(hal_device_enable): removed
(filter_func): don't handle all DeviceBooting etc. signals. Splitted
PropertyChanged into PropertyChanged, PropertyAdded, PropertyRemoved
callbacks
(hal_device_property_watch_all): new function
(hal_device_add_property_watch): new function
(hal_device_remove_property_watch): new function
* libhal/libhal.h: Removed all common constants since they were all
state contstants. Removed LibHalDeviceBooting etc. typedefs. Added
typedefs for PropertyAdded, PropertyRemoved callbacks. Changed type
of LibHalFunctions. Added property for property_watch functions.
* tools/Makefile.am: Added rules to buils lshal, hal_get_property
and hal_set_property programs
* tools/lshal.c: new file
* tools/hal_get_property.c: new file
* tools/hal_set_property.c: new file
* tools/device-manager/DeviceManager.py: Don't reference State
property as it is not available anymore
* tools/linux/Makefile.am: Make sure hal.hotplug links statically,
otherwise libdbus-1.so cannot be found unless installed in /usr/lib
* tools/linux/hal_hotplug.c: Include unistd.h to shut up the compiler
2003-12-20 David Zeuthen <david@fubar.dk>
* Doxyfile.in: Remove agents/linux26/sysfs, Add hald/linux and
tools/linux. Change RECURSIVE to NO.
* configure.in: Add AM_PATH_PYTHON. Add --with-hwdata option and
search for places normally placed at RedHat and Debian. Require
version 0.20 of D-BUS (Martin Waitz).
Make USE_MAINTAINER_MODE an AM_CONDITIONAL. Don't check for libpci.
Default D-BUS system.d directory to our own prefix. Add --with-hotplug
option to specify the hotplug.d directory. Default to /etc/hotplug.d.
Add tools/device-manager/Makefile. Print out HWDATA_DIR,
LINUX_HOTPLUG_DIR.
* hald: All source files, s/LOG_/HAL_/. Fixup Doxygen documentation
* hald/logger.c: new file
* hald/logger.h: change logging macros
* hald/Makefile.am: add logger.c to SOURCES
* hald/linux/linux_class_input.c (process_input_proc_info):
Use EV_SYN if EV_RST is not defined
* tools/Makefile.am: add device-manager to SUBDIRS
* tools/device-manager/Makefile.am: new file; generates Const.py
with correct version and paths. Installs into the python program and
data into $(datadir)/hal/device-manager. Links from $(bindir) to the
installation location.
* tools/device-manager/Const.py.in: new file
* tools/device-manager/Const.py: Removed from CVS; now autogenerated
from Const.py.in
* tools/device-manager/Representation.py: Prefix with Const.DATADIR
when loading png files
* tools/device-manager/DeviceManager.py: Prefix with Const.DATADIR
when loading glade file
* tools/linux/Makefile.am: Move hal.hotplug to libexec from bin.
Create symlink in /etc/hotplug.d on install.
2003-12-15 David Zeuthen <david@fubar.dk>
* hald/device_store.c (ds_init): Don't require callback functions
(ds_add_cb_newcap): new function
(ds_add_cb_property_changed): new function
(ds_add_cb_gdl_changed): new function
(ds_device_destroy): call all registered callbacks
(ds_gdl_add): call all registered callbacks
(ds_property_set_string): call all registered callbacks
(ds_property_set_int): call all registered callbacks
(ds_property_set_bool): call all registered callbacks
(ds_property_set_double): call all registered callbacks
(ds_property_remove): call all registered callbacks
(ds_device_merge): call new capability on target for all capabilities
on source
(ds_add_capability): call all registered callbacks
(ds_query_capability): new function
* hald/device_store.h: Add new prototypes
* hald/main.c (main): Register callbacks we used to give to ds_init()
* hald/linux/linux_class_net (visit_class_device_net): Fixed bug where
the net.ethernet capability was set on "Experimental Ethernet" instead
on "Ethernet"
(mdio_read): new function
(link_detection_process): new function
(link_detection_timer_handler): new function
(link_detection_add): new function
(link_detection_remove): new function
(new_capability): new function
(gdl_changed): new function
(linux_class_net_init): Register callbacks for new_capability and
gdl_changed. Add timer for checking link status every second
2003-12-14 David Zeuthen <david@fubar.dk>
* doc/TODO: New file! Contains a high-level TODO list as a complement
to the @todo's embedded in the source code.
* hald/device_store.c (xstrdup): new function
(ds_init): Require a callback to when the GDL changes
(async_find_timeout_fn): new function
(async_find_check_new_addition): new function
(ds_device_async_find_by_key_value_string): new function
(ds_device_find_by_key_value_string): new function
(ds_device_new): use xstrdup
(ds_gdl_add): check for pending async finds; notify about GDL change
(ds_device_set_udi): use xstrdup
(ds_property_set_string): use xstrdup
(ds_property_set_int): use xstrdup
(ds_property_set_bool): use xstrdup
(ds_property_set_double): use xstrdup
(ds_add_capability): new function
* hald/device_store.h: Add prototypes and required datatypes for
public functions added in device_store.c
* hald/main.c (gdl_changed): new function
(main): Call OS specific elements; see hald/linux
* hald/linux: New directory holding files for device probing and
hotplug handling on Linux 2.6. All the logic from
agents/linux26/sysfs is ported over to use the local HAL interface
in hald.
It's a major change, but I'm sure it's worth it. It's
simply more efficient having a single daemon and, more
importantly, it's easier to manage. The monitoring code still
needs to be ported over.
This is the last major change before 0.2 is released.
* hald/Makefile.am: Add sources from linux and linux/libsysfs
* hald/osspec.h: new file
* tools/linux/hal_hotplug.c: New simple program for translating a
hotplug event into a D-BUS messages
* hal.conf: Add interface for listening to D-BUS messages originating
from Linux Hotplug
* Makefile.am: Apply patch from Martin Waitz for smarter installation
of D-BUS policy file. Remove reference to agents; add tools to SUBDIRS
* configure.in: Remove all agents; add Makefile generation for tools
and tools/linux
2003-12-14 Anders Carlsson <andersca@gnome.org>
* configure.in: Fix config message
2003-12-08 David Zeuthen <david@fubar.dk>
* agents/linux26/sysfs/hal_monitor.c:
(etc_mtab_process_all_block_devices): s/volume./block./
(udev_filter_func): new function for filtering D-BUS messages from udev
(setup_udev_listener): setup filter for udev messages
(hal_monitor_enter): Listen to D-BUS messages
* agents/linux26/sysfs/main.c:
(hal_sysfs_probe): Use global sysfs path
(device_hotplug_add): Use global sysfs path
(device_hotplug_remove): Use global sysfs path
(drivers_collect): Use global sysfs path
(mainloop_integration): Save D-BUS connection object for later use
(main): Get sysfs mount path once and for all
* agents/linux26/sysfs/main.h: Add dbus_connection and sysfs_mount_path
as extern variables
* hald/main.c:
(device_query_capability): new function
(filter_function): add check for Device.QueryCapability
* libhal/libhal.c: Minor formatting stuff
* examples/volumed/volumed.py: Crude example of volume manager now
that we got udev integration in place. It doesn't really mount anything
but prints out when it should mount. You'll need a very recent udev
from BitKeeper with D-BUS enabled (got the patch accepted today)
2003-12-06 David Zeuthen <david@fubar.dk>
* tools/device-manager/hal-device-manager.glade: Forgot to add file
2003-12-06 David Zeuthen <david@fubar.dk>
* agents/linux26/sysfs/hal_monitor.c (ethmon_mdio_read): new function
(ethmon_process): new function
(ethmon_timeout): new function
(ethmon_add): new function
(ethmon_remove): new function
(ethernet_process_all_devices): new function
(device_added): new function
(device_new_capability): new function
(device_removed): new function
(hal_monitor_enter): Initiate monitoring of link status on ethernet
devices
* agents/linux26/sysfs/hal_net.c (visit_class_device_net): Shuffle
the code around so the capability is not set before the properties
under the capability namespace
* agents/linux26/sysfs/main.c: Add device_new_capability in
hal_functions variable
* agents/linux26/sysfs/main.c: Add device_new_capability so it is
visible in other translation units
* hald/main.c (manager_send_signal_new_capability): new function
(device_add_capability): new function
* libhal/libhal.c (hal_free_string_array): Fixed critical bug
(hal_device_add_capability): Use new method on hal daemon instead
of local modification
(filter_func): Fix bug such that signals DeviceAdded and DeviceRemoved
are intercepted on the Manager interface. Add check for NewCapability
signal.
(main): More precise match rule for intercepting signals
* libhal/libhal.h: Add NewCapability callback
* tools/device-manager/DeviceManager.py: Fix a stupid bug where
we tried to call a get_current_focus_udi() method that is no more
2003-12-03 David Zeuthen <david@fubar.dk>
* agents/linux26/sysfs/hal_net.c (visit_class_device_net): Change
mac address to be split into two 24-bit sizes. s/ethernet/net.ethernet/
* libhal/libhal.c (hal_find_all_devices): Put trailing NULL in result
(hal_manager_find_device_string_match): Put trailing NULL in result
(hal_find_device_by_capability): Put trailing NULL in result
* tools/device-manager/hal-device-manager/Representation.y:
Simplify icon selection code
2003-12-03 David Zeuthen <david@fubar.dk>
* tools/device-manager: new directory with tools/hal-device-manager
split into many files
* agents/linux26/sysfs/hal_block.c (visit_device_block): Set
Capability and Category properties
* agents/linux26/sysfs/hal_input.c (get_input_proc_cur_info_obj): new
function
(process_input_proc_info): Set Capability and Category properties
* agents/linux26/sysfs/hal_monitor.c
(etc_mtab_process_all_block_devices): Set some properties under
the volume namespace
* agents/linux26/sysfs/hal_net.c (visit_class_device_net): Set
Capability and Category properties; set MAC address under
namespace ethernet for Ethernet net devices
* agents/linux26/sysfs/hal_pci.c (visit_device_pci): Set
Capability and Category properties
(pci_add_caps_from_class): new function
* agents/linux26/sysfs/hal_usb.c (visit_device_usb_interface): Set
Capability and Category properties
(usb_add_caps_from_class): new function
* hald/main.c (manager_find_device_by_capability): new function
(filter_function): Add call
* libhal/libhal.c (hal_get_all_devices): Convert from d-bus string
array.
(hal_manager_find_device_string_match): Convert from d-bus string
array.
(hal_device_add_capability): new function
(hal_device_query_capability): new function
(hal_find_device_by_capability): new function
* libhal/libhal.h: Add prototypes
2003-12-01 David Zeuthen <david@fubar.dk>
* agents/linux26/sysfs/hal_monitor.c: new file, the /etc/mtab
monitoring code is still a bit cheesy (especially the sleep(1) :-)
Someone with more linux-skills will hopefully rewrite it some day!
* agents/linux26/sysfs/hal_monitor.h: new file
* agents/linux26/sysfs/hal_usb.c (visit_device_usb): Fixed potential
bug for whitespace-strip loop
* agents/linux26/sysfs/main.c (hal_sysfs_probe): Call
etc_mtab_process_all_block_devices() to inspect /etc/mtab and set
correct information for the block devices that is already mounted
(main): Add new option --monitor to start in monitoring mode. Right
now only /etc/mtab is monitored but network link detection is planned.
* tools/hal-device-manager: Don't rebuild entire tree if properties
on a device is changing but just get the changes from hald and change
the internal representation. Helps performance a lot.
2003-11-30 David Zeuthen <david@fubar.dk>
* agents/linux26/sysfs/hal_net.c: new file
* agents/linux26/sysfs/hal_net.h: new file
* agents/linux26/sysfs/hal_input.c: new file
* agents/linux26/sysfs/hal_input.h: new file
* agents/linux26/sysfs/Makefile.am: Add net and input to filelist
* agents/linux26/sysfs/hal_pci.c (visit_device_pci): Set driver
property.
(hal_pci_init): Collect drivers
* agents/linux26/sysfs/hal_usb.c (visit_device_usb): Set driver
property. Compute and set linux.kernel_devname; the name that
the kernel uses to uniquely identify the device
(visit_device_usb_interface): Set driver property
(hal_usb_init): Collect drivers
* agents/linux26/sysfs/main.c (find_num): Gracefully handle errors
(find_udi_from_sysfs_path): allow max_time_to_try to be zero
(find_udi_by_key_value): new function
(visit_class_device): support for net class devices
(hal_sysfs_probe): support for net class devices
(device_hotplug_add): support for input and net class
(device_hotplug_remove): support for input and net class devices
(drivers_add_entry): new function
(drivers_lookup): new function
(drivers_collect): new function
(main): support for input and net class devices
* agents/linux26/sysfs/main.h: Add new prototypes
* tools/hal-device-manager: Fix a bug that slowed down the app
when the devices are changing. Many other changes
* tools/hal-device-manager.glade: Add menu and gnome-app
* tools/fdo-logo.png: new (binary) file
2003-11-27 David Zeuthen <david@fubar.dk>
* libhal/libhal.c (hal_initialized): Fixed stupied error that prevented
libhal from compiling
2003-11-27 David Zeuthen <david@fubar.dk>
* agents/linux26/sysfs/hal-sysfs-agent.c: Removed; splitted into
multiple files; added scsi, ide and block probing + hotplugging;
many many changes..
* agents/linux26/sysfs/main.c: new file
* agents/linux26/sysfs/main.h: new file
* agents/linux26/sysfs/hal_usb.c: new file
* agents/linux26/sysfs/hal_usb.h: new file
* agents/linux26/sysfs/hal_pci.c: new file
* agents/linux26/sysfs/hal_pci.h: new file
* agents/linux26/sysfs/hal_ide.c: new file
* agents/linux26/sysfs/hal_ide.h: new file
* agents/linux26/sysfs/hal_scsi.c: new file
* agents/linux26/sysfs/hal_scsi.h: new file
* agents/linux26/sysfs/hal_block.c: new file
* agents/linux26/sysfs/hal_block.h: new file
* agents/linux26/sysfs/Makefile.am: Changed to reference new files
* fdi/10generic/generic-hid-mouse.fdi: remove
* fdi/10generic/generic-usb-hub.fdi: remove
* fdi/10generic/usb-classes.fdi: new file
* hald/device_info.c: Add support for bool in fdi-files
* libhal/libhal.c: Allow caller to pass NULL in libhal_init()
* tools/hal-device-manager: Don't show (most) virtual devices
2003-11-23 David Zeuthen <david@fubar.dk>
* agents/linux26/sysfs/hal-sysfs-agent.c: USB interfaces now have
their own device which has the USB device as the parent
(usbif_compute_udi): new function
(visit_device_usb_interface): create a new independent device for
the interface
* tools/hal-device-manager: Add support for bus usbif
2003-11-23 David Zeuthen <david@fubar.dk>
* agents/linux26/sysfs/hal-sysfs-agent.c:
(usb_compute_udi): Make the device configuration entry part of the
device udi; use serial number, if available.
(find_usb_device_from_interface_sysfs_path): new function
(visit_device_usb_interface): Bugfix in white-space stripping
(visit_device): Make visit of children optional
(device_hotplug_add): Don't visit children when adding devices; handle
interfaces seperately. Consequently the interfaces appear later.
Added syslog calls.
NOTE: Need to wait for enabling an USB device until all interfaces are
collected.
(device_hotplug_remove): Added syslog calls
(main): Moved hotplug call after getopt switch, and handle all sorts
of events.
* tools/hal-device-manager: Call update_device_list() whenever a
property changes; this is quite ineffective and should be changed
later.
2003-11-22 David Zeuthen <david@fubar.dk>
* COPYING: Updated to mention some source files may be LGPL also
* Doxyfile: Updated to use doxygen 1.3.4
* Doxyfile.in: Updated to use doxygen 1.3.4
* configure.in: Don't build agents/linux/usb/Makefile; we've
dropped 2.4 support. Build agents/linux26/sysfs/libsysfs/Makefile
* agents/Makefile.am: Don't build in agents/linux
* agents/linux26/sysfs/Makefile.am : Build in libsysfs
* agents/linux26/sysfs/hal-sysfs-agent.c: Now using sysfsutils 0.3
(bus_support_append_device): removed
(bus_support_find_bus): removed
(visit_device_usb_interface): Don't require device UDI to be
given; find it self
(visit_device_usb): Don't manually visit USB interfaces
(visit_device): Change to recursively visit children in device
hierachy
(visit_device_tree): removed
(visit_root_device): removed
(bus_support_collect): removed; not neccesary with sysfsutils 0.3
since we can get the bus from there
* agents/linux26/sysfs/libsysfs: New directory for holding local
copy of sysfsutils 0.3.
* agents/linux26/sysfs/libsysfs/Makefile.am : new file
* agents/linux26/sysfs/libsysfs/dlist.c : new file
* agents/linux26/sysfs/libsysfs/dlist.h : new file
* agents/linux26/sysfs/libsysfs/libsysfs.h : new file
* agents/linux26/sysfs/libsysfs/sysfs.h : new file
* agents/linux26/sysfs/libsysfs/sysfs_bus.c : new file
* agents/linux26/sysfs/libsysfs/sysfs_class.c : new file
* agents/linux26/sysfs/libsysfs/sysfs_device.c : new file
* agents/linux26/sysfs/libsysfs/sysfs_dir.c : new file
* agents/linux26/sysfs/libsysfs/sysfs_driver.c : new file
* agents/linux26/sysfs/libsysfs/sysfs_utils.c : new file
* agents/linux26/sysfs/libsysfs/ : new file
2003-11-22 David Zeuthen <david@fubar.dk>
* agents/linux26/sysfs/hal-sysfs-agent.c: Implementing parsing of
/proc/bus/usb/devices to merge information currently not present
in sysfs. Quite a pain, but it seems to work... Still need some
cleanup though
(find_num): new function
(find_double): new function
(find_bcd2): new function
(find_string): new function
(usb_proc_find_virtual_hub): new function
(usb_proc_find_virtual_hub_child): new function
(usb_proc_find_on_hub): new function
(usb_proc_handle_topology): new function
(usb_proc_handle_device_info): new function
(usb_proc_device_done): new function
(usb_proc_parse_line): new function
(usb_proc_parse): new function
(visitor_usb_device): Locate and merge properties from /proc
(main): Parse USB stuff from /proc/bus/usb/devices
* tools/hal-device-manager: Add USB version
* tools/hal-device-manager.glade: Add USB version
2003-11-18 David Zeuthen <david@fubar.dk>
* agents/linux26/sysfs/hal-sysfs-agent.c: Use usb.ids if
available.
(find_parent_udi_from_sysfs_path): Sleep if parent device not
found on hotplug; Fixes the issue of hotplugging a hub with many
devices attached to it
(visit_device_usb): Fix segfault when stripping whitespace off empty
string. Provide guess for Vendor, Product properties
(visit_device_pci): Provide guess for Vendor, Product properties
* hald/main.c (manager_get_all_devices): Only return devices in the GDL
(manager_find_device_string_match): Only match on devices in the GDL
* libhal/libhal.c: Various documentation clarifications
* tools/hal-device-manager: Use icons and Vendor, Product properties.
Added "Advanced" tab page for showing all properties in a list.
* tools/hal-device-manager.glade: Added "Advanced" tab page for
showing all properties in a list.
* tools/bus-usb.png: new (binary) file
* tools/bus-pci.png: new (binary) file
* tools/lshal.py: Sort properties
2003-11-16 David Zeuthen <david@fubar.dk>
* agents/linux26 : new directory; for Linux 2.6 agents
* agents/linux26/Makefile.am: new file
* agents/linux26/sysfs/hal-sysfs-agent.c: new file; inspects sysfs
on Linux 2.6 and adds USB, PCI devices found there. Currently works
with both --probe and in hotplug situations. Block devices are planned
real soon now.
* agents/linux26/sysfs/Makefile.am: new file
* tools/hal-device-manager: Added support for PCI devices
* tools/hal-device-manager.glade: Added PCI page in device_notebook
* libhal/libhal.h: Added hal_manager_find_device_string_match()
* libhal/libhal.c (hal_manager_find_device_string_match): new function
* hald/main.c (manager_find_device_string_match): new function
* configure.in: add agents/linux26/Makefile, agents/linux26/Makefile
* Doxyfile.in: add agents/linux26/sysfs
* Doxyfile: add agents/linux26/sysfs
2003-11-15 David Zeuthen <david@fubar.dk>
* agents/linux/usb/usb_agent.c (usb_compute_parents): Remove calls
to free(); we are causing segfaults because of we are interferring
with D-BUS memory management
(usb_compute_parent): Remove calls to free(); same reason
(usb_probe): Call usb_compute_parents()
(usb_hotplug): Remove calls to free(); same as above; compute parents
for all USB devices every time a single device is added/removed
(main): Sleep for one second before handling hotplug event to allow
the kernel to update /proc/bus/usb/devices
* hald/device_info.h: new file
* hald/device_info.c: new file
* hald/Makefile.am: add device_info.[ch]
* hald/device_store.h: Change signature of
HalDevicePropertyChangeCallback with an added parameter to allow
the callback handler to see if a device have been added
* hald/device_store.c: Change to new signature of property_change_cb
* hald/logger.h: Don't print LOG_TRACE()
* hald/main.c (device_enable): Call di_search_and_merge() to handle
.fdi files
(agent_manager_commit_to_gdl): Call ds_gdl_add()
(filter_func): Don't log entry on every method invocation
(property_changed): Implement
* tools/hal-device-manager: Use Product, Vendor, Category properties to
display information, if available. Handle property changed; reloads
device tree when a Parent property changes. Subscribe to signals
org.freedesktop.Hal.Device interface to catch property changes
* tools/lshal.py: Listen to property changes on device objects
* fdi: new directory
* fdi/10generic: new directory
* fdi/20freedesktop: new directory
* fdi/10generic/generic-usb-hub.fdi: new file
* fdi/10generic/generic-hid-mouse.fdi: new file
* fdi/20freedesktop/ibm-usb-hub-keyboard.fdi: new file
* fdi/20freedesktop/lexar-cf-card-reader.fdi: new file
2003-11-11 David Zeuthen <david@fubar.dk>
* Doxyfile: new file, added so we can generate doxygen documentation
without having to run autogen.sh
2003-11-11 David Zeuthen <david@fubar.dk>
* tools/hal-device-manager: new file, GUI device manager using PyGTK
* tools/hal-device-manager.glade: new file
* agents/linux/usb/Makefile.am: rename program to hal-usb-agent.hotplug
so it works with the linux-hotplug event multiplexor
* agents/linux/usb/usb_agent.c (usb_hotplug): implement
(handle_device_info2): drop usb.revisionProduct; use usb.bcdDevice
instead
(handle_config_desc): set usb.config.%d.isActive property
(usb_compute_parent): new function
(usb_rename_and_maybe_add): new function
(usb_hotplug_get_minimal): new function
* hald/main.c (manager_send_signal_device_added): new function
(manager_send_signal_device_removed): new function
(agent_manager_commit_to_gdl): send out signal using above function
(agent_manager_remove): send out signal using above function
(test): removed
* libhal/libhal.c (hal_device_print): new function
* libhal/libhal.h: add prototype for hal_device_print()
* tools/lshal.py: print device types, reprint device list when
receiving D-BUS signals from the HAL daemon
2003-11-09 David Zeuthen <david@fubar.dk>
* agents/linux/usb/usb_agent.c (usage): Fixed typo from --remove to
--probe. Cosmetic
(usb_device_set_parent): New function
(usb_compute_parents): New function
(usb_probe): Set Parent for devices after probe and filtering/renaming
* hald/device_store.h: ds_device_destroy now returns void
* hald/device_store.c (ds_device_destroy): now return void
* libhal/libhal.c: Tidied up error reporting to be __FILE__ __LINE__
* COPYING: New file
2003-11-08 David Zeuthen <david@fubar.dk>
* HACKING: Fixed typo
2003-11-06 David Zeuthen <david@fubar.dk>
* hal.conf: Changed to work with D-BUS head
2003-11-05 David Zeuthen <david@fubar.dk>
* Initial module creation; moved HAL 0.1 out of the way
|