hw/xen: Remove deadcode
PATCH 1/1 hw/xen: Remove deadcode
From: "Dr. David Alan Gilbert" <[email protected]>
xen_be_copy_grant_refs is unused since 2019's
19f87870ba ("xen: remove the legacy 'xen_disk' backend")
xen_config_dev_console is unused since 2018's
6d7c06c213 ("Remove broken Xen PV domain builder")
Remove them.
--- hw/xen/xen-legacy-backend.c | 18 ------------------ hw/xen/xen_devconfig.c | 8 -------- include/hw/xen/xen-legacy-backend.h | 5 ----- 3 files changed, 31 deletions(-)
hw/xen/xen-legacy-backend.c +0 -18
@@ -147,24 +147,6 @@ void xen_be_unmap_grant_refs(struct XenLegacyDevice *xendev, void *ptr, } } -int xen_be_copy_grant_refs (struct XenLegacyDevice *xendev, -bool to_domain, -XenGrantCopySegment segs[], -unsigned int nr_segs) -{ -int rc; - -assert (xendev->ops->flags &DEVOPS_FLAG_NEED_GNTDEV ); - - rc =qemu_xen_gnttab_grant_copy (xendev->gnttabdev, to_domain, xen_domid, - segs, nr_segs,NULL ); -if (rc) { -xen_pv_printf (xendev,0 ,"xengnttab_grant_copy failed: %s\n" , -strerror (-rc)); - } -return rc; -} -/* * get xen backend device, allocate a new one if it doesn't exist. */
hw/xen/xen_devconfig.c +0 -8
@@ -66,11 +66,3 @@ int xen_config_dev_vkbd(int vdev)xen_config_dev_dirs ("vkbd" ,"vkbd" , vdev, fe, be,sizeof (fe));return xen_config_dev_all (fe, be); } - -int xen_config_dev_console (int vdev) -{ -char fe[256 ], be[256 ]; - -xen_config_dev_dirs ("console" ,"console" , vdev, fe, be,sizeof (fe)); -return xen_config_dev_all (fe, be); -}
include/hw/xen/xen-legacy-backend.h +0 -5
@@ -50,10 +50,6 @@ void *xen_be_map_grant_refs(struct XenLegacyDevice *xendev, uint32_t *refs,void xen_be_unmap_grant_refs (struct XenLegacyDevice *xendev,void *ptr,uint32_t *refs,unsigned int nr_refs); -int xen_be_copy_grant_refs (struct XenLegacyDevice *xendev, -bool to_domain,XenGrantCopySegment segs[], -unsigned int nr_segs); -static inline void *xen_be_map_grant_ref (struct XenLegacyDevice *xendev,uint32_t ref,int prot) {
@@ -70,6 +66,5 @@ static inline void xen_be_unmap_grant_ref(struct XenLegacyDevice *xendev,void xen_config_cleanup (void );int xen_config_dev_vfb (int vdev,const char *type);int xen_config_dev_vkbd (int vdev); -int xen_config_dev_console (int vdev);#endif /* HW_XEN_LEGACY_BACKEND_H */
Signature · 1 line
2.46.0
Quoted 11 lines · On Tue, Sep 17, 2024 at 01:22:12AM +0100, [email protected] wrote:
From: "Dr. David Alan Gilbert" <[email protected]>
xen_be_copy_grant_refsis unused since 2019's
19f87870ba("xen: remove the legacy 'xen_disk' backend")
xen_config_dev_consoleis unused since 2018's
6d7c06c213("Remove broken Xen PV domain builder")Remove them.
Signed-off-by Dr. David Alan Gilbert <[email protected]>
Thanks,
Signature · 5 lines
Anthony Perard | Vates XCP-ng Developer XCP-ng & Xen Orchestra - Vates solutions web: https://vates.tech
Edgar E. Iglesias
Reviewed-byQuoted 9 lines · Anthony PERARD
Quoted 8 lines · On Tue, Sep 17, 2024 at 01:22:12AM +0100, [email protected] wrote:
From: "Dr. David Alan Gilbert" <[email protected]>
xen_be_copy_grant_refsis unused since 2019's
19f87870ba("xen: remove the legacy 'xen_disk' backend")
xen_config_dev_consoleis unused since 2018's
6d7c06c213("Remove broken Xen PV domain builder")
Quoted 7 lines
Quoted 3 lines
Remove them.
Signed-off-by Dr. David Alan Gilbert <[email protected]>Acked-by Anthony PERARD <[email protected]>Thanks,
Cheers,
Edgar
Quoted 78 lines · On 17/09/2024 02.22, [email protected] wrote:
From: "Dr. David Alan Gilbert" <[email protected]>
xen_be_copy_grant_refsis unused since 2019's
19f87870ba("xen: remove the legacy 'xen_disk' backend")
xen_config_dev_consoleis unused since 2018's
6d7c06c213("Remove broken Xen PV domain builder")Remove them.
Signed-off-by Dr. David Alan Gilbert <[email protected]>--- hw/xen/xen-legacy-backend.c | 18 ------------------ hw/xen/xen_devconfig.c | 8 -------- include/hw/xen/xen-legacy-backend.h | 5 ----- 3 files changed, 31 deletions(-)hw/xen/xen-legacy-backend.c +0
-18@@ -147,24 +147,6 @@ void xen_be_unmap_grant_refs(struct XenLegacyDevice *xendev, void *ptr, } } -int xen_be_copy_grant_refs (struct XenLegacyDevice *xendev, -bool to_domain, -XenGrantCopySegment segs[], -unsigned int nr_segs) -{ -int rc; - -assert (xendev->ops->flags &DEVOPS_FLAG_NEED_GNTDEV ); - - rc =qemu_xen_gnttab_grant_copy (xendev->gnttabdev, to_domain, xen_domid, - segs, nr_segs,NULL ); -if (rc) { -xen_pv_printf (xendev,0 ,"xengnttab_grant_copy failed: %s\n" , -strerror (-rc)); - } -return rc; -} -/* * get xen backend device, allocate a new one if it doesn't exist. */ hw/xen/xen_devconfig.c +0
-8@@ -66,11 +66,3 @@ int xen_config_dev_vkbd(int vdev)xen_config_dev_dirs ("vkbd" ,"vkbd" , vdev, fe, be,sizeof (fe));return xen_config_dev_all (fe, be); } - -int xen_config_dev_console (int vdev) -{ -char fe[256 ], be[256 ]; - -xen_config_dev_dirs ("console" ,"console" , vdev, fe, be,sizeof (fe)); -return xen_config_dev_all (fe, be); -}include/hw/xen/xen-legacy-backend.h +0
-4@@ -50,10 +50,6 @@ void *xen_be_map_grant_refs(struct XenLegacyDevice *xendev, uint32_t *refs,void xen_be_unmap_grant_refs (struct XenLegacyDevice *xendev,void *ptr,uint32_t *refs,unsigned int nr_refs); -int xen_be_copy_grant_refs (struct XenLegacyDevice *xendev, -bool to_domain,XenGrantCopySegment segs[], -unsigned int nr_segs); -static inline void *xen_be_map_grant_ref (struct XenLegacyDevice *xendev,uint32_t ref,int prot) {
include/hw/xen/xen-legacy-backend.h static inline void xen_be_unmap_grant_ref(struct XenLegacyDevice *xendev, · line 70
Quoted 6 lines
include/hw/xen/xen-legacy-backend.h +0
-1@@ -70,6 +66,5 @@ static inline void xen_be_unmap_grant_ref(struct XenLegacyDevice *xendev,void xen_config_cleanup (void );int xen_config_dev_vfb (int vdev,const char *type);int xen_config_dev_vkbd (int vdev); -int xen_config_dev_console (int vdev);#endif /* HW_XEN_LEGACY_BACKEND_H */