summary refs log tree commit diff stats
path: root/results/scraper/launchpad/788697
blob: 60207f0c93592988c45e3d1f0823aee8e6ce0cc2 (plain) (blame)
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
[PowerPC] [patch] mtmsr does not preserve high bits of MSR

The mtmsr instruction on 64-bit PPC does not preserve the high-order 32-bits of the MSR the way it is supposed to, instead setting them to 0, which takes 64-bit code out of 64-bit mode. There is some code that does the right thing, but it brokenly only preserves these bits when the thread is not in 64-bit mode (i.e. when it doesn't matter). The attached patch unconditionally enables this code when TARGET_PPC64 is set, per the ISA spec, which fixes early boot failures trying to start FreeBSD/powerpc64 under qemu.




On 26.05.2011, at 18:09, Nathan Whitehorn wrote:

> ** Patch added: "mtmstr.diff"
>   https://bugs.launchpad.net/bugs/788697/+attachment/2143748/+files/mtmstr.diff
> 
> -- 
> You received this bug notification because you are a member of qemu-
> devel-ml, which is subscribed to QEMU.
> https://bugs.launchpad.net/bugs/788697
> 
> Title:
>  [PowerPC] [patch] mtmsr does not preserve high bits of MSR
> 
> Status in QEMU:
>  New
> 
> Bug description:
>  The mtmsr instruction on 64-bit PPC does not preserve the high-order
>  32-bits of the MSR the way it is supposed to, instead setting them to
>  0, which takes 64-bit code out of 64-bit mode. There is some code that
>  does the right thing, but it brokenly only preserves these bits when
>  the thread is not in 64-bit mode (i.e. when it doesn't matter). The
>  attached patch unconditionally enables this code when TARGET_PPC64 is
>  set, per the ISA spec, which fixes early boot failures trying to start
>  FreeBSD/powerpc64 under qemu.
> 

Please send the patch as proper patch to the ML and CC me.

Alex



On 05/26/11 11:45, agraf wrote:
> On 26.05.2011, at 18:09, Nathan Whitehorn wrote:
>
>> ** Patch added: "mtmstr.diff"
>>    https://bugs.launchpad.net/bugs/788697/+attachment/2143748/+files/mtmstr.diff
>>
>> --
>> You received this bug notification because you are a member of qemu-
>> devel-ml, which is subscribed to QEMU.
>> https://bugs.launchpad.net/bugs/788697
>>
>> Title:
>>   [PowerPC] [patch] mtmsr does not preserve high bits of MSR
>>
>> Status in QEMU:
>>   New
>>
>> Bug description:
>>   The mtmsr instruction on 64-bit PPC does not preserve the high-order
>>   32-bits of the MSR the way it is supposed to, instead setting them to
>>   0, which takes 64-bit code out of 64-bit mode. There is some code that
>>   does the right thing, but it brokenly only preserves these bits when
>>   the thread is not in 64-bit mode (i.e. when it doesn't matter). The
>>   attached patch unconditionally enables this code when TARGET_PPC64 is
>>   set, per the ISA spec, which fixes early boot failures trying to start
>>   FreeBSD/powerpc64 under qemu.
>>
>
> Please send the patch as proper patch to the ML and CC me.

What isn't proper about the patch? I'm happy to re-email it, but don't 
want things to be in the wrong format.
-Nathan



On 27.05.2011, at 01:33, Nathan Whitehorn wrote:

> On 05/26/11 11:45, agraf wrote:
>> On 26.05.2011, at 18:09, Nathan Whitehorn wrote:
>> 
>>> ** Patch added: "mtmstr.diff"
>>>   https://bugs.launchpad.net/bugs/788697/+attachment/2143748/+files/mtmstr.diff
>>> 
>>> --
>>> You received this bug notification because you are a member of qemu-
>>> devel-ml, which is subscribed to QEMU.
>>> https://bugs.launchpad.net/bugs/788697
>>> 
>>> Title:
>>>  [PowerPC] [patch] mtmsr does not preserve high bits of MSR
>>> 
>>> Status in QEMU:
>>>  New
>>> 
>>> Bug description:
>>>  The mtmsr instruction on 64-bit PPC does not preserve the high-order
>>>  32-bits of the MSR the way it is supposed to, instead setting them to
>>>  0, which takes 64-bit code out of 64-bit mode. There is some code that
>>>  does the right thing, but it brokenly only preserves these bits when
>>>  the thread is not in 64-bit mode (i.e. when it doesn't matter). The
>>>  attached patch unconditionally enables this code when TARGET_PPC64 is
>>>  set, per the ISA spec, which fixes early boot failures trying to start
>>>  FreeBSD/powerpc64 under qemu.
>>> 
>> 
>> Please send the patch as proper patch to the ML and CC me.
> 
> What isn't proper about the patch? I'm happy to re-email it, but don't 
> want things to be in the wrong format.
> -Nathan

The patch needs a patch description in its header and a subject line (all of which are present in the bug, so it's a simple matter of copy&paste). Basically at the end of the day, I should be able to save the mail and "git am" on it and simply have it in my tree :).

Also, does this get FreeBSD booting up to anything useful, so I can verify it helps?


Alex



On 05/26/11 18:47, agraf wrote:
> On 27.05.2011, at 01:33, Nathan Whitehorn wrote:
>
>> On 05/26/11 11:45, agraf wrote:
>>> On 26.05.2011, at 18:09, Nathan Whitehorn wrote:
>>>
>>>> ** Patch added: "mtmstr.diff"
>>>>    https://bugs.launchpad.net/bugs/788697/+attachment/2143748/+files/mtmstr.diff
>>>>
>>>> --
>>>> You received this bug notification because you are a member of qemu-
>>>> devel-ml, which is subscribed to QEMU.
>>>> https://bugs.launchpad.net/bugs/788697
>>>>
>>>> Title:
>>>>   [PowerPC] [patch] mtmsr does not preserve high bits of MSR
>>>>
>>>> Status in QEMU:
>>>>   New
>>>>
>>>> Bug description:
>>>>   The mtmsr instruction on 64-bit PPC does not preserve the high-order
>>>>   32-bits of the MSR the way it is supposed to, instead setting them to
>>>>   0, which takes 64-bit code out of 64-bit mode. There is some code that
>>>>   does the right thing, but it brokenly only preserves these bits when
>>>>   the thread is not in 64-bit mode (i.e. when it doesn't matter). The
>>>>   attached patch unconditionally enables this code when TARGET_PPC64 is
>>>>   set, per the ISA spec, which fixes early boot failures trying to start
>>>>   FreeBSD/powerpc64 under qemu.
>>>>
>>> Please send the patch as proper patch to the ML and CC me.
>> What isn't proper about the patch? I'm happy to re-email it, but don't
>> want things to be in the wrong format.
>> -Nathan
> The patch needs a patch description in its header and a subject line
> (all of which are present in the bug, so it's a simple matter of
> copy&paste). Basically at the end of the day, I should be able to save
> the mail and "git am" on it and simply have it in my tree :).
>
> Also, does this get FreeBSD booting up to anything useful, so I can
> verify it helps?

OK, I'll send this one out to today. The other issue I'm having (aside 
from our own bugs), is that SPR_PIR is not implemented for the POWER7 
target. The architecture manual claims it is implemented on all Book-3S 
compliant CPUs, but it seems to be implemented sort of ad-hoc in 
target-ppc.c (e.g. the 604, 620, and 7400 have it, but not the 750, 970, 
or POWER7).
-Nathan



On 31.05.2011, at 15:35, Nathan Whitehorn wrote:

> On 05/26/11 18:47, agraf wrote:
>> On 27.05.2011, at 01:33, Nathan Whitehorn wrote:
>> 
>>> On 05/26/11 11:45, agraf wrote:
>>>> On 26.05.2011, at 18:09, Nathan Whitehorn wrote:
>>>> 
>>>>> ** Patch added: "mtmstr.diff"
>>>>>   https://bugs.launchpad.net/bugs/788697/+attachment/2143748/+files/mtmstr.diff
>>>>> 
>>>>> --
>>>>> You received this bug notification because you are a member of qemu-
>>>>> devel-ml, which is subscribed to QEMU.
>>>>> https://bugs.launchpad.net/bugs/788697
>>>>> 
>>>>> Title:
>>>>>  [PowerPC] [patch] mtmsr does not preserve high bits of MSR
>>>>> 
>>>>> Status in QEMU:
>>>>>  New
>>>>> 
>>>>> Bug description:
>>>>>  The mtmsr instruction on 64-bit PPC does not preserve the high-order
>>>>>  32-bits of the MSR the way it is supposed to, instead setting them to
>>>>>  0, which takes 64-bit code out of 64-bit mode. There is some code that
>>>>>  does the right thing, but it brokenly only preserves these bits when
>>>>>  the thread is not in 64-bit mode (i.e. when it doesn't matter). The
>>>>>  attached patch unconditionally enables this code when TARGET_PPC64 is
>>>>>  set, per the ISA spec, which fixes early boot failures trying to start
>>>>>  FreeBSD/powerpc64 under qemu.
>>>>> 
>>>> Please send the patch as proper patch to the ML and CC me.
>>> What isn't proper about the patch? I'm happy to re-email it, but don't
>>> want things to be in the wrong format.
>>> -Nathan
>> The patch needs a patch description in its header and a subject line
>> (all of which are present in the bug, so it's a simple matter of
>> copy&paste). Basically at the end of the day, I should be able to save
>> the mail and "git am" on it and simply have it in my tree :).
>> 
>> Also, does this get FreeBSD booting up to anything useful, so I can
>> verify it helps?
> 
> OK, I'll send this one out to today. The other issue I'm having (aside 
> from our own bugs), is that SPR_PIR is not implemented for the POWER7 
> target. The architecture manual claims it is implemented on all Book-3S 
> compliant CPUs, but it seems to be implemented sort of ad-hoc in 
> target-ppc.c (e.g. the 604, 620, and 7400 have it, but not the 750, 970, 
> or POWER7).

So the reason POWER7 doesn't have it is probably because it simply does the same as 970. Why 970 doesn't register PIR, I don't know, but to me it sounds like a plain bug :). Just send a patch, CC me and David Gibson.

Alex



As far as I can see, the issue has been fixed here:
http://git.qemu.org/?p=qemu.git;a=commitdiff;h=8018dc63aab936f1a5
... so closing this ticket now.