Linux Audio

Check our new training course

Loading...
v3.1
 1What:           /sys/class/pktcdvd/
 2Date:           Oct. 2006
 3KernelVersion:  2.6.20
 4Contact:        Thomas Maier <balagi@justmail.de>
 5Description:
 6
 7sysfs interface
 8---------------
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 9
10The pktcdvd module (packet writing driver) creates
11these files in the sysfs:
12(<devid> is in format  major:minor )
13
14/sys/class/pktcdvd/
15    add            (0200)  Write a block device id (major:minor)
16                           to create a new pktcdvd device and map
17                           it to the block device.
18
19    remove         (0200)  Write the pktcdvd device id (major:minor)
20                           to it to remove the pktcdvd device.
21
22    device_map     (0444)  Shows the device mapping in format:
23                             pktcdvd[0-7] <pktdevid> <blkdevid>
24
25/sys/class/pktcdvd/pktcdvd[0-7]/
26    dev                   (0444) Device id
27    uevent                (0200) To send an uevent.
28
29/sys/class/pktcdvd/pktcdvd[0-7]/stat/
30    packets_started       (0444) Number of started packets.
31    packets_finished      (0444) Number of finished packets.
32
33    kb_written            (0444) kBytes written.
34    kb_read               (0444) kBytes read.
35    kb_read_gather        (0444) kBytes read to fill write packets.
36
37    reset                 (0200) Write any value to it to reset
38                                 pktcdvd device statistic values, like
39                                 bytes read/written.
40
41/sys/class/pktcdvd/pktcdvd[0-7]/write_queue/
42    size                  (0444) Contains the size of the bio write
43                                 queue.
44
45    congestion_off        (0644) If bio write queue size is below
46                                 this mark, accept new bio requests
47                                 from the block layer.
48
49    congestion_on         (0644) If bio write queue size is higher
50                                 as this mark, do no longer accept
51                                 bio write requests from the block
52                                 layer and wait till the pktcdvd
53                                 device has processed enough bio's
54                                 so that bio write queue size is
55                                 below congestion off mark.
56                                 A value of <= 0 disables congestion
57                                 control.
58
59
60Example:
61--------
62To use the pktcdvd sysfs interface directly, you can do:
63
64# create a new pktcdvd device mapped to /dev/hdc
65echo "22:0" >/sys/class/pktcdvd/add
66cat /sys/class/pktcdvd/device_map
67# assuming device pktcdvd0 was created, look at stat's
68cat /sys/class/pktcdvd/pktcdvd0/stat/kb_written
69# print the device id of the mapped block device
70fgrep pktcdvd0 /sys/class/pktcdvd/device_map
71# remove device, using pktcdvd0 device id   253:0
72echo "253:0" >/sys/class/pktcdvd/remove
v5.4
 
 
 
 
 
 
 1sysfs interface
 2---------------
 3The pktcdvd module (packet writing driver) creates the following files in the
 4sysfs: (<devid> is in the format major:minor)
 5
 6What:		/sys/class/pktcdvd/add
 7What:		/sys/class/pktcdvd/remove
 8What:		/sys/class/pktcdvd/device_map
 9Date:		Oct. 2006
10KernelVersion:	2.6.20
11Contact:	Thomas Maier <balagi@justmail.de>
12Description:
13
14		add:		(WO) Write a block device id (major:minor) to
15				create a new pktcdvd device and map it to the
16				block device.
17
18		remove:		(WO) Write the pktcdvd device id (major:minor)
19				to remove the pktcdvd device.
20
21		device_map:	(RO) Shows the device mapping in format:
22				pktcdvd[0-7] <pktdevid> <blkdevid>
23
24
25What:		/sys/class/pktcdvd/pktcdvd[0-7]/dev
26What:		/sys/class/pktcdvd/pktcdvd[0-7]/uevent
27Date:		Oct. 2006
28KernelVersion:	2.6.20
29Contact:	Thomas Maier <balagi@justmail.de>
30Description:
31		dev:	(RO) Device id
32
33		uevent:	(WO) To send a uevent
34
35
36What:		/sys/class/pktcdvd/pktcdvd[0-7]/stat/packets_started
37What:		/sys/class/pktcdvd/pktcdvd[0-7]/stat/packets_finished
38What:		/sys/class/pktcdvd/pktcdvd[0-7]/stat/kb_written
39What:		/sys/class/pktcdvd/pktcdvd[0-7]/stat/kb_read
40What:		/sys/class/pktcdvd/pktcdvd[0-7]/stat/kb_read_gather
41What:		/sys/class/pktcdvd/pktcdvd[0-7]/stat/reset
42Date:		Oct. 2006
43KernelVersion:	2.6.20
44Contact:	Thomas Maier <balagi@justmail.de>
45Description:
46		packets_started:	(RO) Number of started packets.
47
48		packets_finished:	(RO) Number of finished packets.
49
50		kb_written:		(RO) kBytes written.
51
52		kb_read:		(RO) kBytes read.
53
54		kb_read_gather:		(RO) kBytes read to fill write packets.
55
56		reset:			(WO) Write any value to it to reset
57					pktcdvd device statistic values, like
58					bytes read/written.
59
60
61What:		/sys/class/pktcdvd/pktcdvd[0-7]/write_queue/size
62What:		/sys/class/pktcdvd/pktcdvd[0-7]/write_queue/congestion_off
63What:		/sys/class/pktcdvd/pktcdvd[0-7]/write_queue/congestion_on
64Date:		Oct. 2006
65KernelVersion:	2.6.20
66Contact:	Thomas Maier <balagi@justmail.de>
67Description:
68		size:		(RO) Contains the size of the bio write queue.
69
70		congestion_off:	(RW) If bio write queue size is below this mark,
71				accept new bio requests from the block layer.
72
73		congestion_on:	(RW) If bio write queue size is higher as this
74				mark, do no longer accept bio write requests
75				from the block layer and wait till the pktcdvd
76				device has processed enough bio's so that bio
77				write queue size is below congestion off mark.
78				A value of <= 0 disables congestion control.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
79
80
81Example:
82--------
83To use the pktcdvd sysfs interface directly, you can do:
84
85# create a new pktcdvd device mapped to /dev/hdc
86echo "22:0" >/sys/class/pktcdvd/add
87cat /sys/class/pktcdvd/device_map
88# assuming device pktcdvd0 was created, look at stat's
89cat /sys/class/pktcdvd/pktcdvd0/stat/kb_written
90# print the device id of the mapped block device
91fgrep pktcdvd0 /sys/class/pktcdvd/device_map
92# remove device, using pktcdvd0 device id   253:0
93echo "253:0" >/sys/class/pktcdvd/remove