[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 113/126] hw/ide: Declare ide_get_[geometry/bios_chs_trans] in 'hw/
From: |
Philippe Mathieu-Daudé |
Subject: |
[PULL 113/126] hw/ide: Declare ide_get_[geometry/bios_chs_trans] in 'hw/ide/internal.h' |
Date: |
Mon, 27 Feb 2023 15:02:00 +0100 |
ide_get_geometry() and ide_get_bios_chs_trans() are only
used by the TYPE_PC_MACHINE.
"hw/ide.h" is a mixed bag of lost IDE declarations. In order
to remove this (almost) pointless header soon, move these
declarations to "hw/ide/internal.h".
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Message-Id: <20230220091358.17038-18-philmd@linaro.org>
---
hw/i386/pc.c | 3 ++-
include/hw/ide.h | 4 ----
include/hw/ide/internal.h | 4 ++++
3 files changed, 6 insertions(+), 5 deletions(-)
diff --git a/hw/i386/pc.c b/hw/i386/pc.c
index 98c2becc11..992951c107 100644
--- a/hw/i386/pc.c
+++ b/hw/i386/pc.c
@@ -33,7 +33,8 @@
#include "hw/i386/vmport.h"
#include "sysemu/cpus.h"
#include "hw/block/fdc.h"
-#include "hw/ide.h"
+#include "hw/ide/internal.h"
+#include "hw/ide/isa.h"
#include "hw/pci/pci.h"
#include "hw/pci/pci_bus.h"
#include "hw/pci-bridge/pci_expander_bridge.h"
diff --git a/include/hw/ide.h b/include/hw/ide.h
index 24a7aa2925..db963bdb77 100644
--- a/include/hw/ide.h
+++ b/include/hw/ide.h
@@ -3,10 +3,6 @@
#include "exec/memory.h"
-int ide_get_geometry(BusState *bus, int unit,
- int16_t *cyls, int8_t *heads, int8_t *secs);
-int ide_get_bios_chs_trans(BusState *bus, int unit);
-
/* ide/core.c */
void ide_drive_get(DriveInfo **hd, int max_bus);
diff --git a/include/hw/ide/internal.h b/include/hw/ide/internal.h
index c2b794150f..d9f1f77dd5 100644
--- a/include/hw/ide/internal.h
+++ b/include/hw/ide/internal.h
@@ -647,6 +647,10 @@ void ide_bus_init(IDEBus *idebus, size_t idebus_size,
DeviceState *dev,
int bus_id, int max_units);
IDEDevice *ide_bus_create_drive(IDEBus *bus, int unit, DriveInfo *drive);
+int ide_get_geometry(BusState *bus, int unit,
+ int16_t *cyls, int8_t *heads, int8_t *secs);
+int ide_get_bios_chs_trans(BusState *bus, int unit);
+
int ide_handle_rw_error(IDEState *s, int error, int op);
#endif /* HW_IDE_INTERNAL_H */
--
2.38.1
- [PULL 116/126] hw/ide/piix: Remove unused includes, (continued)
- [PULL 116/126] hw/ide/piix: Remove unused includes, Philippe Mathieu-Daudé, 2023/02/27
- [PULL 104/126] hw/ide: Remove unused 'qapi/qapi-types-run-state.h', Philippe Mathieu-Daudé, 2023/02/27
- [PULL 109/126] hw/ide: Rename ide_register_restart_cb -> ide_bus_register_restart_cb, Philippe Mathieu-Daudé, 2023/02/27
- [PULL 114/126] hw/ide/ioport: Remove unnecessary includes, Philippe Mathieu-Daudé, 2023/02/27
- [PULL 115/126] hw/ide/pci: Unexport bmdma_active_if(), Philippe Mathieu-Daudé, 2023/02/27
- [PULL 118/126] hw/ide/piix: Refactor pci_piix_init_ports as pci_piix_init_bus per bus, Philippe Mathieu-Daudé, 2023/02/27
- [PULL 120/126] hw/ide/pci: Add PCIIDEState::isa_irq[], Philippe Mathieu-Daudé, 2023/02/27
- [PULL 123/126] dump: Clean included headers, Philippe Mathieu-Daudé, 2023/02/27
- [PULL 125/126] dump: Add create_win_dump() stub for non-x86 targets, Philippe Mathieu-Daudé, 2023/02/27
- [PULL 110/126] hw/ide: Rename ide_exec_cmd() -> ide_bus_exec_cmd(), Philippe Mathieu-Daudé, 2023/02/27
- [PULL 113/126] hw/ide: Declare ide_get_[geometry/bios_chs_trans] in 'hw/ide/internal.h',
Philippe Mathieu-Daudé <=
- [PULL 121/126] dump: Replace tswapN() -> cpu_to_dumpN(), Philippe Mathieu-Daudé, 2023/02/27
- [PULL 119/126] hw/ide/via: Replace magic 2 value by ARRAY_SIZE / MAX_IDE_DEVS, Philippe Mathieu-Daudé, 2023/02/27
- [PULL 122/126] dump: Replace TARGET_PAGE_SIZE -> qemu_target_page_size(), Philippe Mathieu-Daudé, 2023/02/27
- [PULL 124/126] dump: Simplify compiling win_dump.o by introducing win_dump_available(), Philippe Mathieu-Daudé, 2023/02/27
- [PULL 117/126] hw/ide/piix: Pass Error* to pci_piix_init_ports() for better error msg, Philippe Mathieu-Daudé, 2023/02/27
- [PULL 126/126] ui/cocoa: user friendly characters for release mouse, Philippe Mathieu-Daudé, 2023/02/27
- Re: [RESEND PULL 000/126] Buildsys / QOM / QDev / UI patches for 2023-02-27, Peter Maydell, 2023/02/27