blob: 849e9bc277d561a724d60d075e8a473860277622 (
plain)
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
|
string
ap_device_opt()
{
return "l";
}
string
ap_device_usage()
{
return "\n";
}
static void
ap_device_showusage()
{
printf("usage : ap_device %s", ap_device_usage());
}
string
ap_device_help()
{
return "Help";
}
int
ap_device()
{
int i;
struct list_head *next;
struct list_head *head;
struct ap_device *off = 0;
head = (struct list_head *)&ap_device_list;
next = (struct list_head *)head->next;
if (!next)
return 1;
while (next != head)
{
struct ap_device *device;
struct list_head *next1, *head1;
device = (struct ap_device *)((unsigned long)next - ((unsigned long)&(off->list)));
head1 = (struct list_head *)&(device->pendingq);
next1 = (struct list_head *)device->pendingq.next;
while (next1 != head1)
{
struct ap_message *apmsg;
apmsg = (struct ap_message *)next1;
if (apmsg->length) {
memset((char *)apmsg->message, 'L', apmsg->length);
memset((char *)&(apmsg->length), 'L', 0x8);
}
next1 = (struct list_head *)apmsg->list.next;
}
head1 = (struct list_head *)&(device->requestq);
next1 = (struct list_head *)device->requestq.next;
while (next1 != head1)
{
struct ap_message *apmsg;
apmsg = (struct ap_message *)next1;
if (apmsg->length) {
memset((char *)apmsg->message, 'L', apmsg->length);
memset((char *)&(apmsg->length), 'L', 0x8);
}
next1 = (struct list_head *)apmsg->list.next;
}
next = (struct list_head *)device->list.next;
}
return 1;
}
|