Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit fff52494 authored by Logan Gunthorpe's avatar Logan Gunthorpe Committed by Greg Kroah-Hartman
Browse files

NTB: ntb_tool: reading the link file should not end in a NULL byte



[ Upstream commit 912e12813dd03c602e4922fc34709ec4d4380cf0 ]

When running ntb_test this warning is issued:

./ntb_test.sh: line 200: warning: command substitution: ignored null
byte in input

This is caused by the kernel returning one more byte than is necessary
when reading the link file.

Reduce the number of bytes read back to 2 as it was before the
commit that regressed this.

Fixes: 7f46c8b3 ("NTB: ntb_tool: Add full multi-port NTB API support")
Signed-off-by: default avatarLogan Gunthorpe <logang@deltatee.com>
Acked-by: default avatarAllen Hubbe <allenbh@gmail.com>
Tested-by: default avatarAlexander Fomichev <fomichev.ru@gmail.com>
Signed-off-by: default avatarJon Mason <jdmason@kudzu.us>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 03a8dbf4
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment