* [PATCH] xen/bitmap: Make bitmap_long_to_byte() and bitmap_byte_to_long() static
@ 2021-08-09 14:41 Jane Malalane
2021-08-10 7:18 ` Jan Beulich
0 siblings, 1 reply; 2+ messages in thread
From: Jane Malalane @ 2021-08-09 14:41 UTC (permalink / raw)
To: Xen-devel
Cc: Jane Malalane, Andrew Cooper, George Dunlap, Ian Jackson,
Jan Beulich, Julien Grall, Stefano Stabellini, Wei Liu
Functions made static as there are no external callers.
Suggested-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Jane Malalane <jane.malalane@citrix.com>
---
CC: Andrew Cooper <andrew.cooper3@citrix.com>
CC: George Dunlap <george.dunlap@citrix.com>
CC: Ian Jackson <iwj@xenproject.org>
CC: Jan Beulich <jbeulich@suse.com>
CC: Julien Grall <julien@xen.org>
CC: Stefano Stabellini <sstabellini@kernel.org>
CC: Wei Liu <wl@xen.org>
---
xen/common/bitmap.c | 8 ++++----
xen/include/xen/bitmap.h | 3 ---
2 files changed, 4 insertions(+), 7 deletions(-)
diff --git a/xen/common/bitmap.c b/xen/common/bitmap.c
index b7aa2db7c7..bbc3554ae1 100644
--- a/xen/common/bitmap.c
+++ b/xen/common/bitmap.c
@@ -338,7 +338,7 @@ EXPORT_SYMBOL(bitmap_allocate_region);
#ifdef __BIG_ENDIAN
-void bitmap_long_to_byte(uint8_t *bp, const unsigned long *lp, int nbits)
+static void bitmap_long_to_byte(uint8_t *bp, const unsigned long *lp, int nbits)
{
unsigned long l;
int i, j, b;
@@ -354,7 +354,7 @@ void bitmap_long_to_byte(uint8_t *bp, const unsigned long *lp, int nbits)
clamp_last_byte(bp, nbits);
}
-void bitmap_byte_to_long(unsigned long *lp, const uint8_t *bp, int nbits)
+static void bitmap_byte_to_long(unsigned long *lp, const uint8_t *bp, int nbits)
{
unsigned long l;
int i, j, b;
@@ -371,13 +371,13 @@ void bitmap_byte_to_long(unsigned long *lp, const uint8_t *bp, int nbits)
#elif defined(__LITTLE_ENDIAN)
-void bitmap_long_to_byte(uint8_t *bp, const unsigned long *lp, int nbits)
+static void bitmap_long_to_byte(uint8_t *bp, const unsigned long *lp, int nbits)
{
memcpy(bp, lp, (nbits+7)/8);
clamp_last_byte(bp, nbits);
}
-void bitmap_byte_to_long(unsigned long *lp, const uint8_t *bp, int nbits)
+static void bitmap_byte_to_long(unsigned long *lp, const uint8_t *bp, int nbits)
{
/* We may need to pad the final longword with zeroes. */
if (nbits & (BITS_PER_LONG-1))
diff --git a/xen/include/xen/bitmap.h b/xen/include/xen/bitmap.h
index 634a259645..e9175ab54a 100644
--- a/xen/include/xen/bitmap.h
+++ b/xen/include/xen/bitmap.h
@@ -270,9 +270,6 @@ static inline void bitmap_clear(unsigned long *map, unsigned int start,
#undef bitmap_switch
#undef bitmap_bytes
-void bitmap_long_to_byte(uint8_t *bp, const unsigned long *lp, int nbits);
-void bitmap_byte_to_long(unsigned long *lp, const uint8_t *bp, int nbits);
-
struct xenctl_bitmap;
int xenctl_bitmap_to_bitmap(unsigned long *bitmap,
const struct xenctl_bitmap *xenctl_bitmap,
--
2.11.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] xen/bitmap: Make bitmap_long_to_byte() and bitmap_byte_to_long() static
2021-08-09 14:41 [PATCH] xen/bitmap: Make bitmap_long_to_byte() and bitmap_byte_to_long() static Jane Malalane
@ 2021-08-10 7:18 ` Jan Beulich
0 siblings, 0 replies; 2+ messages in thread
From: Jan Beulich @ 2021-08-10 7:18 UTC (permalink / raw)
To: Jane Malalane
Cc: Andrew Cooper, George Dunlap, Ian Jackson, Julien Grall,
Stefano Stabellini, Wei Liu, Xen-devel
On 09.08.2021 16:41, Jane Malalane wrote:
> Functions made static as there are no external callers.
>
> Suggested-by: Andrew Cooper <andrew.cooper3@citrix.com>
> Signed-off-by: Jane Malalane <jane.malalane@citrix.com>
Acked-by: Jan Beulich <jbeulich@suse.com>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-08-10 7:19 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-09 14:41 [PATCH] xen/bitmap: Make bitmap_long_to_byte() and bitmap_byte_to_long() static Jane Malalane
2021-08-10 7:18 ` Jan Beulich
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.