diff mbox

[20/23] ppc: Suppress unused default drives

Message ID 1344519084-21847-21-git-send-email-armbru@redhat.com
State New
Headers show

Commit Message

Markus Armbruster Aug. 9, 2012, 1:31 p.m. UTC
Cc: Alexander Graf <agraf@suse.de>
Cc: Andreas Färber <andreas.faerber@web.de>
Cc: qemu-ppc@nongnu.org

Suppress default floppy drive for machines ref405ep, taihu, bamboo,
mac99, g3beige, virtex-ml507.

Suppress default CD-ROM drive for machines ref405ep, taihu, bamboo,
virtex-ml507.

Suppress default SD card drive for machines ref405ep, taihu, bamboo,
mac88, g3beige, prep, virtex-ml507.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
---
 hw/ppc405_boards.c | 6 ++++++
 hw/ppc440_bamboo.c | 3 +++
 hw/ppc_newworld.c  | 2 ++
 hw/ppc_oldworld.c  | 2 ++
 hw/ppc_prep.c      | 1 +
 hw/virtex_ml507.c  | 3 +++
 6 files changed, 17 insertions(+)

Comments

Andreas Färber Aug. 9, 2012, 2:20 p.m. UTC | #1
Am 09.08.2012 15:31, schrieb Markus Armbruster:
> Cc: Alexander Graf <agraf@suse.de>
> Cc: Andreas Färber <andreas.faerber@web.de>
> Cc: qemu-ppc@nongnu.org
> 
> Suppress default floppy drive for machines ref405ep, taihu, bamboo,
> mac99, g3beige, virtex-ml507.
> 
> Suppress default CD-ROM drive for machines ref405ep, taihu, bamboo,
> virtex-ml507.
> 
> Suppress default SD card drive for machines ref405ep, taihu, bamboo,
> mac88, g3beige, prep, virtex-ml507.

mac99

> 
> Signed-off-by: Markus Armbruster <armbru@redhat.com>
> ---
>  hw/ppc405_boards.c | 6 ++++++
>  hw/ppc440_bamboo.c | 3 +++
>  hw/ppc_newworld.c  | 2 ++
>  hw/ppc_oldworld.c  | 2 ++
>  hw/ppc_prep.c      | 1 +
>  hw/virtex_ml507.c  | 3 +++
>  6 files changed, 17 insertions(+)
[...]
> diff --git a/hw/ppc_newworld.c b/hw/ppc_newworld.c
> index 4e2a6e6..1e41c2b 100644
> --- a/hw/ppc_newworld.c
> +++ b/hw/ppc_newworld.c
> @@ -423,6 +423,8 @@ static QEMUMachine core99_machine = {
>      .desc = "Mac99 based PowerMAC",
>      .init = ppc_core99_init,
>      .max_cpus = MAX_CPUS,
> +    .no_floppy = 1,
> +    .no_sdcard = 1,
>  #ifdef TARGET_PPC64
>      .is_default = 1,
>  #endif

Ack.

> diff --git a/hw/ppc_oldworld.c b/hw/ppc_oldworld.c
> index f2c6908..bcecc0a 100644
> --- a/hw/ppc_oldworld.c
> +++ b/hw/ppc_oldworld.c
> @@ -338,6 +338,8 @@ static QEMUMachine heathrow_machine = {
>      .desc = "Heathrow based PowerMAC",
>      .init = ppc_heathrow_init,
>      .max_cpus = MAX_CPUS,
> +    .no_floppy = 1,
> +    .no_sdcard = 1,
>  #ifndef TARGET_PPC64
>      .is_default = 1,
>  #endif

Ack for SD.

Not sure about the floppy. I thought the beige Old World machines used
to have a floppy with some incompatible Apple formatting... Did they use
a controller we don't implement? If so, then .no_floppy should get a
comment.

> diff --git a/hw/ppc_prep.c b/hw/ppc_prep.c
> index be2b268..9393022 100644
> --- a/hw/ppc_prep.c
> +++ b/hw/ppc_prep.c
> @@ -694,6 +694,7 @@ static QEMUMachine prep_machine = {
>      .desc = "PowerPC PREP platform",
>      .init = ppc_prep_init,
>      .max_cpus = MAX_CPUS,
> +    .no_sdcard = 1,
>  };
>  
>  static void prep_machine_init(void)

Ack.

> diff --git a/hw/virtex_ml507.c b/hw/virtex_ml507.c
> index 79bc0d1..62b56c0 100644
> --- a/hw/virtex_ml507.c
> +++ b/hw/virtex_ml507.c
> @@ -264,6 +264,9 @@ static QEMUMachine virtex_machine = {
>      .name = "virtex-ml507",
>      .desc = "Xilinx Virtex ML507 reference design",
>      .init = virtex_init,
> +    .no_floppy = 1,
> +    .no_cdrom = 1,
> +    .no_sdcard = 1,
>  };
>  
>  static void virtex_machine_init(void)

Markus, independent of this patch, might it make sense to invert the
logic here so that machine authors don't need to know the list of what
.no_ options to specify?

Andreas
Markus Armbruster Aug. 9, 2012, 2:54 p.m. UTC | #2
Andreas Färber <andreas.faerber@web.de> writes:

> Am 09.08.2012 15:31, schrieb Markus Armbruster:
>> Cc: Alexander Graf <agraf@suse.de>
>> Cc: Andreas Färber <andreas.faerber@web.de>
>> Cc: qemu-ppc@nongnu.org
>> 
>> Suppress default floppy drive for machines ref405ep, taihu, bamboo,
>> mac99, g3beige, virtex-ml507.
>> 
>> Suppress default CD-ROM drive for machines ref405ep, taihu, bamboo,
>> virtex-ml507.
>> 
>> Suppress default SD card drive for machines ref405ep, taihu, bamboo,
>> mac88, g3beige, prep, virtex-ml507.
>
> mac99

Oopsie.  Thanks!

>> Signed-off-by: Markus Armbruster <armbru@redhat.com>
>> ---
>>  hw/ppc405_boards.c | 6 ++++++
>>  hw/ppc440_bamboo.c | 3 +++
>>  hw/ppc_newworld.c  | 2 ++
>>  hw/ppc_oldworld.c  | 2 ++
>>  hw/ppc_prep.c      | 1 +
>>  hw/virtex_ml507.c  | 3 +++
>>  6 files changed, 17 insertions(+)
> [...]
>> diff --git a/hw/ppc_newworld.c b/hw/ppc_newworld.c
>> index 4e2a6e6..1e41c2b 100644
>> --- a/hw/ppc_newworld.c
>> +++ b/hw/ppc_newworld.c
>> @@ -423,6 +423,8 @@ static QEMUMachine core99_machine = {
>>      .desc = "Mac99 based PowerMAC",
>>      .init = ppc_core99_init,
>>      .max_cpus = MAX_CPUS,
>> +    .no_floppy = 1,
>> +    .no_sdcard = 1,
>>  #ifdef TARGET_PPC64
>>      .is_default = 1,
>>  #endif
>
> Ack.
>
>> diff --git a/hw/ppc_oldworld.c b/hw/ppc_oldworld.c
>> index f2c6908..bcecc0a 100644
>> --- a/hw/ppc_oldworld.c
>> +++ b/hw/ppc_oldworld.c
>> @@ -338,6 +338,8 @@ static QEMUMachine heathrow_machine = {
>>      .desc = "Heathrow based PowerMAC",
>>      .init = ppc_heathrow_init,
>>      .max_cpus = MAX_CPUS,
>> +    .no_floppy = 1,
>> +    .no_sdcard = 1,
>>  #ifndef TARGET_PPC64
>>      .is_default = 1,
>>  #endif
>
> Ack for SD.
>
> Not sure about the floppy. I thought the beige Old World machines used
> to have a floppy with some incompatible Apple formatting... Did they use
> a controller we don't implement? If so, then .no_floppy should get a
> comment.

I have no idea.  Alex?

>> diff --git a/hw/ppc_prep.c b/hw/ppc_prep.c
>> index be2b268..9393022 100644
>> --- a/hw/ppc_prep.c
>> +++ b/hw/ppc_prep.c
>> @@ -694,6 +694,7 @@ static QEMUMachine prep_machine = {
>>      .desc = "PowerPC PREP platform",
>>      .init = ppc_prep_init,
>>      .max_cpus = MAX_CPUS,
>> +    .no_sdcard = 1,
>>  };
>>  
>>  static void prep_machine_init(void)
>
> Ack.
>
>> diff --git a/hw/virtex_ml507.c b/hw/virtex_ml507.c
>> index 79bc0d1..62b56c0 100644
>> --- a/hw/virtex_ml507.c
>> +++ b/hw/virtex_ml507.c
>> @@ -264,6 +264,9 @@ static QEMUMachine virtex_machine = {
>>      .name = "virtex-ml507",
>>      .desc = "Xilinx Virtex ML507 reference design",
>>      .init = virtex_init,
>> +    .no_floppy = 1,
>> +    .no_cdrom = 1,
>> +    .no_sdcard = 1,
>>  };
>>  
>>  static void virtex_machine_init(void)
>
> Markus, independent of this patch, might it make sense to invert the
> logic here so that machine authors don't need to know the list of what
> .no_ options to specify?

Leaning towards yes.
Alexander Graf Aug. 9, 2012, 5:44 p.m. UTC | #3
On 09.08.2012, at 16:54, Markus Armbruster <armbru@redhat.com> wrote:

> Andreas Färber <andreas.faerber@web.de> writes:
> 
>> Am 09.08.2012 15:31, schrieb Markus Armbruster:
>>> Cc: Alexander Graf <agraf@suse.de>
>>> Cc: Andreas Färber <andreas.faerber@web.de>
>>> Cc: qemu-ppc@nongnu.org
>>> 
>>> Suppress default floppy drive for machines ref405ep, taihu, bamboo,
>>> mac99, g3beige, virtex-ml507.
>>> 
>>> Suppress default CD-ROM drive for machines ref405ep, taihu, bamboo,
>>> virtex-ml507.
>>> 
>>> Suppress default SD card drive for machines ref405ep, taihu, bamboo,
>>> mac88, g3beige, prep, virtex-ml507.
>> 
>> mac99
> 
> Oopsie.  Thanks!
> 
>>> Signed-off-by: Markus Armbruster <armbru@redhat.com>
>>> ---
>>> hw/ppc405_boards.c | 6 ++++++
>>> hw/ppc440_bamboo.c | 3 +++
>>> hw/ppc_newworld.c  | 2 ++
>>> hw/ppc_oldworld.c  | 2 ++
>>> hw/ppc_prep.c      | 1 +
>>> hw/virtex_ml507.c  | 3 +++
>>> 6 files changed, 17 insertions(+)
>> [...]
>>> diff --git a/hw/ppc_newworld.c b/hw/ppc_newworld.c
>>> index 4e2a6e6..1e41c2b 100644
>>> --- a/hw/ppc_newworld.c
>>> +++ b/hw/ppc_newworld.c
>>> @@ -423,6 +423,8 @@ static QEMUMachine core99_machine = {
>>>     .desc = "Mac99 based PowerMAC",
>>>     .init = ppc_core99_init,
>>>     .max_cpus = MAX_CPUS,
>>> +    .no_floppy = 1,
>>> +    .no_sdcard = 1,
>>> #ifdef TARGET_PPC64
>>>     .is_default = 1,
>>> #endif
>> 
>> Ack.
>> 
>>> diff --git a/hw/ppc_oldworld.c b/hw/ppc_oldworld.c
>>> index f2c6908..bcecc0a 100644
>>> --- a/hw/ppc_oldworld.c
>>> +++ b/hw/ppc_oldworld.c
>>> @@ -338,6 +338,8 @@ static QEMUMachine heathrow_machine = {
>>>     .desc = "Heathrow based PowerMAC",
>>>     .init = ppc_heathrow_init,
>>>     .max_cpus = MAX_CPUS,
>>> +    .no_floppy = 1,
>>> +    .no_sdcard = 1,
>>> #ifndef TARGET_PPC64
>>>     .is_default = 1,
>>> #endif
>> 
>> Ack for SD.
>> 
>> Not sure about the floppy. I thought the beige Old World machines used
>> to have a floppy with some incompatible Apple formatting... Did they use
>> a controller we don't implement? If so, then .no_floppy should get a
>> comment.
> 
> I have no idea.  Alex?

I'd have to check wikipedia all the same :)

Alex
Markus Armbruster Aug. 15, 2012, 12:30 p.m. UTC | #4
Alexander Graf <agraf@suse.de> writes:

> On 09.08.2012, at 16:54, Markus Armbruster <armbru@redhat.com> wrote:
>
>> Andreas Färber <andreas.faerber@web.de> writes:
>> 
>>> Am 09.08.2012 15:31, schrieb Markus Armbruster:
>>>> Cc: Alexander Graf <agraf@suse.de>
>>>> Cc: Andreas Färber <andreas.faerber@web.de>
>>>> Cc: qemu-ppc@nongnu.org
>>>> 
>>>> Suppress default floppy drive for machines ref405ep, taihu, bamboo,
>>>> mac99, g3beige, virtex-ml507.
>>>> 
>>>> Suppress default CD-ROM drive for machines ref405ep, taihu, bamboo,
>>>> virtex-ml507.
>>>> 
>>>> Suppress default SD card drive for machines ref405ep, taihu, bamboo,
>>>> mac88, g3beige, prep, virtex-ml507.
>>> 
>>> mac99
>> 
>> Oopsie.  Thanks!
>> 
>>>> Signed-off-by: Markus Armbruster <armbru@redhat.com>
>>>> ---
>>>> hw/ppc405_boards.c | 6 ++++++
>>>> hw/ppc440_bamboo.c | 3 +++
>>>> hw/ppc_newworld.c  | 2 ++
>>>> hw/ppc_oldworld.c  | 2 ++
>>>> hw/ppc_prep.c      | 1 +
>>>> hw/virtex_ml507.c  | 3 +++
>>>> 6 files changed, 17 insertions(+)
>>> [...]
>>>> diff --git a/hw/ppc_newworld.c b/hw/ppc_newworld.c
>>>> index 4e2a6e6..1e41c2b 100644
>>>> --- a/hw/ppc_newworld.c
>>>> +++ b/hw/ppc_newworld.c
>>>> @@ -423,6 +423,8 @@ static QEMUMachine core99_machine = {
>>>>     .desc = "Mac99 based PowerMAC",
>>>>     .init = ppc_core99_init,
>>>>     .max_cpus = MAX_CPUS,
>>>> +    .no_floppy = 1,
>>>> +    .no_sdcard = 1,
>>>> #ifdef TARGET_PPC64
>>>>     .is_default = 1,
>>>> #endif
>>> 
>>> Ack.
>>> 
>>>> diff --git a/hw/ppc_oldworld.c b/hw/ppc_oldworld.c
>>>> index f2c6908..bcecc0a 100644
>>>> --- a/hw/ppc_oldworld.c
>>>> +++ b/hw/ppc_oldworld.c
>>>> @@ -338,6 +338,8 @@ static QEMUMachine heathrow_machine = {
>>>>     .desc = "Heathrow based PowerMAC",
>>>>     .init = ppc_heathrow_init,
>>>>     .max_cpus = MAX_CPUS,
>>>> +    .no_floppy = 1,
>>>> +    .no_sdcard = 1,
>>>> #ifndef TARGET_PPC64
>>>>     .is_default = 1,
>>>> #endif
>>> 
>>> Ack for SD.
>>> 
>>> Not sure about the floppy. I thought the beige Old World machines used
>>> to have a floppy with some incompatible Apple formatting... Did they use
>>> a controller we don't implement? If so, then .no_floppy should get a
>>> comment.
>> 
>> I have no idea.  Alex?
>
> I'd have to check wikipedia all the same :)

All right, I did: they had some kind of floppy.  No clue what kind.

And we already have a comment:

            /* TOFIX: for now, the second IDE channel is not properly
             *        used by OHW. The Mac floppy disk are not emulated.
             *        For now, OHW cannot boot from the network.
             */

Andreas, still want a comment next to .no_floppy?
Andreas Färber Aug. 15, 2012, 12:40 p.m. UTC | #5
Am 15.08.2012 14:30, schrieb Markus Armbruster:
> Alexander Graf <agraf@suse.de> writes:
> 
>> On 09.08.2012, at 16:54, Markus Armbruster <armbru@redhat.com> wrote:
>>
>>> Andreas Färber <andreas.faerber@web.de> writes:
>>>
>>>> Am 09.08.2012 15:31, schrieb Markus Armbruster:
>>>>> diff --git a/hw/ppc_oldworld.c b/hw/ppc_oldworld.c
>>>>> index f2c6908..bcecc0a 100644
>>>>> --- a/hw/ppc_oldworld.c
>>>>> +++ b/hw/ppc_oldworld.c
>>>>> @@ -338,6 +338,8 @@ static QEMUMachine heathrow_machine = {
>>>>>     .desc = "Heathrow based PowerMAC",
>>>>>     .init = ppc_heathrow_init,
>>>>>     .max_cpus = MAX_CPUS,
>>>>> +    .no_floppy = 1,
>>>>> +    .no_sdcard = 1,
>>>>> #ifndef TARGET_PPC64
>>>>>     .is_default = 1,
>>>>> #endif
>>>>
>>>> Ack for SD.
>>>>
>>>> Not sure about the floppy. I thought the beige Old World machines used
>>>> to have a floppy with some incompatible Apple formatting... Did they use
>>>> a controller we don't implement? If so, then .no_floppy should get a
>>>> comment.
>>>
>>> I have no idea.  Alex?
>>
>> I'd have to check wikipedia all the same :)
> 
> All right, I did: they had some kind of floppy.  No clue what kind.
> 
> And we already have a comment:
> 
>             /* TOFIX: for now, the second IDE channel is not properly
>              *        used by OHW. The Mac floppy disk are not emulated.
>              *        For now, OHW cannot boot from the network.
>              */
> 
> Andreas, still want a comment next to .no_floppy?

Nah, no need then. :)

We should rather spend the time on getting OpenBIOS working with PReP...
o:-)

Andreas
diff mbox

Patch

diff --git a/hw/ppc405_boards.c b/hw/ppc405_boards.c
index 476775d..08f90f1 100644
--- a/hw/ppc405_boards.c
+++ b/hw/ppc405_boards.c
@@ -363,6 +363,9 @@  static QEMUMachine ref405ep_machine = {
     .name = "ref405ep",
     .desc = "ref405ep",
     .init = ref405ep_init,
+    .no_floppy = 1,
+    .no_cdrom = 1,
+    .no_sdcard = 1,
 };
 
 /*****************************************************************************/
@@ -652,6 +655,9 @@  static QEMUMachine taihu_machine = {
     .name = "taihu",
     .desc = "taihu",
     .init = taihu_405ep_init,
+    .no_floppy = 1,
+    .no_cdrom = 1,
+    .no_sdcard = 1,
 };
 
 static void ppc405_machine_init(void)
diff --git a/hw/ppc440_bamboo.c b/hw/ppc440_bamboo.c
index 0dd4dab..5cb0d35 100644
--- a/hw/ppc440_bamboo.c
+++ b/hw/ppc440_bamboo.c
@@ -294,6 +294,9 @@  static QEMUMachine bamboo_machine = {
     .name = "bamboo",
     .desc = "bamboo",
     .init = bamboo_init,
+    .no_floppy = 1,
+    .no_cdrom = 1,
+    .no_sdcard = 1,
 };
 
 static void bamboo_machine_init(void)
diff --git a/hw/ppc_newworld.c b/hw/ppc_newworld.c
index 4e2a6e6..1e41c2b 100644
--- a/hw/ppc_newworld.c
+++ b/hw/ppc_newworld.c
@@ -423,6 +423,8 @@  static QEMUMachine core99_machine = {
     .desc = "Mac99 based PowerMAC",
     .init = ppc_core99_init,
     .max_cpus = MAX_CPUS,
+    .no_floppy = 1,
+    .no_sdcard = 1,
 #ifdef TARGET_PPC64
     .is_default = 1,
 #endif
diff --git a/hw/ppc_oldworld.c b/hw/ppc_oldworld.c
index f2c6908..bcecc0a 100644
--- a/hw/ppc_oldworld.c
+++ b/hw/ppc_oldworld.c
@@ -338,6 +338,8 @@  static QEMUMachine heathrow_machine = {
     .desc = "Heathrow based PowerMAC",
     .init = ppc_heathrow_init,
     .max_cpus = MAX_CPUS,
+    .no_floppy = 1,
+    .no_sdcard = 1,
 #ifndef TARGET_PPC64
     .is_default = 1,
 #endif
diff --git a/hw/ppc_prep.c b/hw/ppc_prep.c
index be2b268..9393022 100644
--- a/hw/ppc_prep.c
+++ b/hw/ppc_prep.c
@@ -694,6 +694,7 @@  static QEMUMachine prep_machine = {
     .desc = "PowerPC PREP platform",
     .init = ppc_prep_init,
     .max_cpus = MAX_CPUS,
+    .no_sdcard = 1,
 };
 
 static void prep_machine_init(void)
diff --git a/hw/virtex_ml507.c b/hw/virtex_ml507.c
index 79bc0d1..62b56c0 100644
--- a/hw/virtex_ml507.c
+++ b/hw/virtex_ml507.c
@@ -264,6 +264,9 @@  static QEMUMachine virtex_machine = {
     .name = "virtex-ml507",
     .desc = "Xilinx Virtex ML507 reference design",
     .init = virtex_init,
+    .no_floppy = 1,
+    .no_cdrom = 1,
+    .no_sdcard = 1,
 };
 
 static void virtex_machine_init(void)