|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [xen stable-4.16] libs/vchan: Fix -Wsingle-bit-bitfield-constant-conversion
commit 3e23155743566e682404fadf81b58c44b4aa1cbf
Author: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
AuthorDate: Tue Aug 8 14:53:42 2023 +0100
Commit: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
CommitDate: Tue Aug 8 14:53:42 2023 +0100
libs/vchan: Fix -Wsingle-bit-bitfield-constant-conversion
Gitlab reports:
init.c:348:18: error: implicit truncation from 'int' to a one-bit wide
bit-field changes value from 1 to -1
[-Werror,-Wsingle-bit-bitfield-constant-conversion]
ctrl->is_server = 1;
^ ~
1 error generated.
make[6]: ***
[/builds/xen-project/people/andyhhp/xen/tools/libs/vchan/../../../tools/Rules.mk:188:
init.o] Error 1
In Xen 4.18, this was fixed with c/s 99ab02f63ea8 ("tools: convert bitfields
to unsigned type") but this is an ABI change which can't be backported.
Swich 1 for -1 to provide a minimally invasive way to fix the build.
No functional change.
Signed-off-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
---
tools/libs/vchan/init.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/libs/vchan/init.c b/tools/libs/vchan/init.c
index c8510e6ce9..89ddf9c464 100644
--- a/tools/libs/vchan/init.c
+++ b/tools/libs/vchan/init.c
@@ -321,7 +321,7 @@ struct libxenvchan *libxenvchan_server_init(struct
xentoollog_logger *logger,
ctrl->ring = NULL;
ctrl->event = NULL;
- ctrl->is_server = 1;
+ ctrl->is_server = -1;
ctrl->server_persist = 0;
ctrl->read.order = min_order(left_min);
--
generated by git-patchbot for /home/xen/git/xen.git#stable-4.16
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |