From patchwork Sat Jul 27 17:11:02 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?J=2E_Neusch=C3=A4fer?= X-Patchwork-Id: 13743766 Received: from mout.gmx.net (mout.gmx.net [212.227.15.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 347361822F8 for ; Sat, 27 Jul 2024 17:11:12 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=212.227.15.19 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722100275; cv=none; b=gjcIsVysdiyHj/A9JsRqlEmUpLEhmrYSz7k1cPFqpxiUPOrsU1eiPgQKMoPxSw5dcQOMa8HZfCiZsFA/I3A8UBem5BaFfQF+CAHfU6e8OMBdI4gJf0gSUPnXP0v+bYyjhgn8wDSx1B4AaCCAanbNJOkg2UZw0JNhybJ58MSCY3Q= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722100275; c=relaxed/simple; bh=2k4psoqOPffmscdCWHgApM8s/rFOSeg/eybuLJR/yZs=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=MtDhvGDgX4bWNjFDjbrhkrG35lyWZe98XxRLJHXUJopUezg2++8OMhVE0f1TmsrfAuFvJkHKYtNDv2gNlE45EiCa5wa5bnjT83c6nPvTXWDo99XH54ITf0bsONP2NfZa69FjQZyca4znZjtCJC0U5hX2Z1OvbkIHxzF7capQBgo= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=gmx.net; spf=pass smtp.mailfrom=gmx.net; dkim=pass (2048-bit key) header.d=gmx.net header.i=j.neuschaefer@gmx.net header.b=rnTojTub; arc=none smtp.client-ip=212.227.15.19 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=gmx.net Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmx.net Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmx.net header.i=j.neuschaefer@gmx.net header.b="rnTojTub" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmx.net; s=s31663417; t=1722100267; x=1722705067; i=j.neuschaefer@gmx.net; bh=swBoFVNFjIlFqqBEQ8QUYMA2NSSds0ph4YbtsEYzyKg=; h=X-UI-Sender-Class:From:Date:Subject:MIME-Version:Content-Type: Content-Transfer-Encoding:Message-Id:References:In-Reply-To:To:Cc: cc:content-transfer-encoding:content-type:date:from:message-id: mime-version:reply-to:subject:to; b=rnTojTubB19Up4jdlc2E9NPUrgWr7HThPmAPsEpafusSIR++UTcVW7GZtOxpz8Lj RrErh9IyMwQa2FUAcdiMQv+ttWLG9mk2NvpwyphgtKPbzbUeCTpiGbCgtVeWTuGd1 y2nnqy6wWMGZKWVBBZlmbSAJ4mpXYibC4lLyvpZknlnlBqGHsWKopWZ6K765lg3rO +LaUTbEOLxvrnk86BCLkOxN+s8ADa2d5JVYxaKI7jc/iCk0M0TD8WW9YYgjwEY+8D gyEShsClNCseyaAhXMqONNSFg8k54CaZAS811Obi83bA6pDrbDmk3tyPun1dK6TWA fewy9S45UTi7AHxCow== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from probook ([89.1.58.183]) by mail.gmx.net (mrgmx004 [212.227.17.190]) with ESMTPSA (Nemesis) id 1M4axg-1sXCyz1Vlm-00B85O; Sat, 27 Jul 2024 19:11:07 +0200 From: =?utf-8?q?J=2E_Neusch=C3=A4fer?= Date: Sat, 27 Jul 2024 19:11:02 +0200 Subject: [PATCH kvmtool v2 1/2] Switch to POSIX version of basename() Precedence: bulk X-Mailing-List: kvm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240727-musl-v2-1-b106252a1cba@gmx.net> References: <20240727-musl-v2-0-b106252a1cba@gmx.net> In-Reply-To: <20240727-musl-v2-0-b106252a1cba@gmx.net> To: kvm@vger.kernel.org Cc: Alyssa Ross , =?utf-8?q?J=2E_Neusch=C3=A4fer?= X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=ed25519-sha256; t=1722100266; l=912; i=j.neuschaefer@gmx.net; s=20240329; h=from:subject:message-id; bh=2m/JDnXc4n6lAD/EHrapM+X4fY61n4spC8jbBUZkrDE=; b=7soL1lPuUdAGjf5pnHbwtaSNSKzMAk+d0x/+5RLnmDM+H0JEPWz7D7rDpPjpjamqrJDZAz0Dt 2NRUFb31fXhDj9B9kzCmkN6yj+XFBSbPV6TiTGscZ2+gMMDbEkTV2bi X-Developer-Key: i=j.neuschaefer@gmx.net; a=ed25519; pk=NIe0bK42wNaX/C4bi6ezm7NJK0IQE+8MKBm7igFMIS4= X-Provags-ID: V03:K1:2oafHmtkoJKAg9jDbY4+jYbc+4LOq0EJaVnqrlbQ/QF+yEjKqCw KF+i12+ilpft6fygPqyq8BYsbrvwCY5MJWDMm95UvK86KN1094la7y4eixKYVCXorAf3vqa Q0/0qyGo9iIUKrAwa4lsINOtzr0hc95rbNVkFp6ojr1G4mK5EiUkzMBNzM6OUvUUCm7vTXO G15n5RbDicaYjP1pEeGkQ== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:nl6Nj17KOZY=;mgFxCfgGYsTwZbOuJM9ALDQcZkB P/NGb2tO/GgJbMHdBe8DzmcuNP3jiCAtIHvqdS3dNMp0w8zb5zdbANUfLi3vM8p60RhMea+XK ncEgqx4iA71hVPrWBqQP9hzEXA4BULF2T/FYXmcwU8Pbjcx88rvTLaXDabyOr6o2BaqMTZot7 NVsyCp9DuyDo75aL9Lg0FRLjsPP9eNnXDNI1dvR6w3Uv7/r018tAeVa5IdNAJmmkE0nwlEa1r LaecPlj0gEBm0DGxjrFN13JaTc0RTBdwiJ3PatsqyK0AYt2MRd4asLPkj8Zm2JAbXu9x0xnOX Oct8iNHSpbuU8PZuMTSBsaDRhe/CgmIDHlgOx96wn8fXv24PB7ddhukk8gphFm2yNGyA+NGkI 6tU9r0woiRu9nczCc3wToVZtnUqlPdbs9OM7dM6IrHx9KBPUW8WBPBkXSMxUSY5mb9yoyAbFg 68fplCgWf3kVhM4R111fmJ5d0uTexDmNxjh6AYf+k21uz3BFARC/lV0jxZspMcZR/S+O0/Av/ 19/g+HqACz6elKpouJbtqgWQ48CAbqTddDX4vWogekqJ6u+v6kdnelvAuH5KMuL+o43zeq9kz FHBlyFAN+r7VcuyLP4KzhUDoz7s32MQKasSKVvVmDn9q0rVL32Ehexqm+FxklPFwsEO3ICO0L Tc/H8c0wp0QZ/XqFX5Gp0Ak+u4inMt8liwQcjq9D9Bh2VI+Pfhldz5y8KneA3aZ67lr7QHjK2 DuHADgdBhEnqs0C/4gQAh64ZP6ESjU5B/DBpTog2l2eiOhRZbDpmgjvHsdmyANk6PK9IQ69cL +5CiebufMx+dJoqVRq3ABRiA== There are two versions of the basename function: The POSIX version is defined in , and glibc additionally provides a GNU-specific version in . musl-libc only provides the POSIX version, resulting in a compilation failure: vfio/core.c:538:22: error: implicit declaration of function 'basename' [-Werror=implicit-function-declaration] 538 | group_name = basename(group_path); | ^~~~~~~~ Reviewed-by: Alyssa Ross Signed-off-by: J. Neuschäfer Reviewed-by: Andre Przywara --- vfio/core.c | 1 + 1 file changed, 1 insertion(+) -- 2.43.0 diff --git a/vfio/core.c b/vfio/core.c index 3ff2c0b..8f88489 100644 --- a/vfio/core.c +++ b/vfio/core.c @@ -3,6 +3,7 @@ #include "kvm/ioport.h" #include +#include #define VFIO_DEV_DIR "/dev/vfio" #define VFIO_DEV_NODE VFIO_DEV_DIR "/vfio" From patchwork Sat Jul 27 17:11:03 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?J=2E_Neusch=C3=A4fer?= X-Patchwork-Id: 13743764 Received: from mout.gmx.net (mout.gmx.net [212.227.15.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5E29153362 for ; Sat, 27 Jul 2024 17:11:12 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=212.227.15.18 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722100274; cv=none; b=lDYGvYZi1GA5Ap/D4HkQO55ddjpcwCBt53xxC+cDiMZnztHrOUytpMrGrLeqUBNOwa5yqkWw5/NFsA9MJvoMBM2uFTg9icUL8LI4Fz03X75nVybO+z4xuUYyjGo/15OfSR6h9c6Vfz5H/W5EYuCsMkBm0tXm048kSv0LwFB1HCo= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722100274; c=relaxed/simple; bh=G1UG7Ym5QWsBDQqrKrtbV3yC3R4jZ+ZAMXPrVuycTlc=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=YTkP34szDdC48wqnoly5vzWyVK2UiG5FjiDcprinc2bw5iBpG0nWowsc37m0Qn19APDJ3+D3N3fXxlFG/31rkoaKWNoIXnblb+pGBs/xlmB/0f2mYc9RwW5r6tG6tpF8AvA+dUCOlMv5gXkOAA5rD3WDJgWhe+6pFpzS6NnFNwo= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=gmx.net; spf=pass smtp.mailfrom=gmx.net; dkim=pass (2048-bit key) header.d=gmx.net header.i=j.neuschaefer@gmx.net header.b=f2WJCzos; arc=none smtp.client-ip=212.227.15.18 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=gmx.net Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmx.net Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmx.net header.i=j.neuschaefer@gmx.net header.b="f2WJCzos" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmx.net; s=s31663417; t=1722100267; x=1722705067; i=j.neuschaefer@gmx.net; bh=G1UG7Ym5QWsBDQqrKrtbV3yC3R4jZ+ZAMXPrVuycTlc=; h=X-UI-Sender-Class:From:Date:Subject:MIME-Version:Content-Type: Content-Transfer-Encoding:Message-Id:References:In-Reply-To:To:Cc: cc:content-transfer-encoding:content-type:date:from:message-id: mime-version:reply-to:subject:to; b=f2WJCzosSh7HOEJhOD50wKYFkjZJhAW52HE4nsCamrOxyKcSgtEoO/TuKsdzG3Bj BfK0/5SBuLrn8wVTX7VUBPEkV4Qxit0S+2nhmSnZxUU+p32P+26X0cCEePHxTNuGU QeyHsgLxSZvaLlicKnBVBVu8SdBnhlX2wN2halN4IhhpgId54CpLwaixCSWehMK/k BrqR+eoYXb/GkI0coI4IMOSPjCUkyjIsB+YTmYuj0hyRNZXSIZ2nwR4Y5LSKSKadq rzFxKmh9gJ2XcKrWOr3ZVuHzbTGfchdveaquG3J53IRVrGT9EfeUCVYWOJcUR+6z6 UKbfeLJNZtT9HKxaXQ== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from probook ([89.1.58.183]) by mail.gmx.net (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1M72oH-1sdXi039Ch-00058L; Sat, 27 Jul 2024 19:11:07 +0200 From: =?utf-8?q?J=2E_Neusch=C3=A4fer?= Date: Sat, 27 Jul 2024 19:11:03 +0200 Subject: [PATCH kvmtool v2 2/2] Get __WORDSIZE from for musl compat Precedence: bulk X-Mailing-List: kvm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240727-musl-v2-2-b106252a1cba@gmx.net> References: <20240727-musl-v2-0-b106252a1cba@gmx.net> In-Reply-To: <20240727-musl-v2-0-b106252a1cba@gmx.net> To: kvm@vger.kernel.org Cc: Alyssa Ross , =?utf-8?q?J=2E_Neusch=C3=A4fer?= X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=ed25519-sha256; t=1722100266; l=613; i=j.neuschaefer@gmx.net; s=20240329; h=from:subject:message-id; bh=tVOKWKwYU+dVSuJDiqNEpg66SUP9EyIq3cbfmNfFK8Y=; b=hK+P0jWNoM9nH+1tVHNZxUHQ1xDZ4rkvhuplKz6IShimJP7cFD8y6ldeERO7FLy93E1oxHRKI 1EAFbJISvGND0JvRyqf+eL+stDf3Eb8soaxgWFWwKpN2mGhw50UFZa3 X-Developer-Key: i=j.neuschaefer@gmx.net; a=ed25519; pk=NIe0bK42wNaX/C4bi6ezm7NJK0IQE+8MKBm7igFMIS4= X-Provags-ID: V03:K1:cps0hYPM52FIxxZbADOopOzlR/CKTRTWsr52WuficotDgm6Ad/T Vd2bxvCiop3VgDFeW31gmS8OG33PUMJiRTZFPJTGO0scxH6Co9ayOa5Q334OIN5jiVY+opn vUF0BvUpdBLTq1N6a3kYvE9plE5UDbHJ4t0vIYmoDxZdGejSsr0uOhAnZeBofJl0hZKrIeF kMesFcrOjmu2wpVE50NWw== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:SKoYa5LO7T4=;/QvVM+OtAjcBRgaNJv9bzP2TQsU W7mEoZWfDayFG6NtxPrBf8vr08j7g3N14Nl/n/JePUj40bm0P/usz3L5+peRUNcHzjUhLjY8t NdhQfccMVy0MbMnaerABUoHHI5tLyRprnmrM90bttUlsmTxJvd5vcpXpwtws+b9lxTk8Loudk KKN/ary+VKJSOKqyhZRr2RsigAGgx0Ro4oXjnCgPgrLSKiE3Jo9/i4N8Mb/PH6FwbpNBxIput Mq27bfRLEs75kUbjHYJRP/H/FF/cwcB/EnRzLh7+YV7+a7cblUQOLaQ5dOhGOJhpPvah4W3qS XAYCshVSEXUomSOArmW9wFTInNxjIT1DhSZeu+yUjtZuEaG6gLOF4Ya8PuSGQTRFI+JOrIPlE Ie7Hwmm+7TWN7Snqy6zlQT0+SyuVtKwz/t8r4GDrZd7/5QLZdAW91zGOIdwEXTzX26jZpCdEE uXNytYgj32sbQioaDuhgdihEEbAKLf1fRSMI/OyHt10O0dlKDxHBwy7Gyc5CRn3bPKJpCLBNh RtXubr3PVC9ti89HqedgFSp3xP0iqHay5w7cUONOj5EzB2RtX/9wTbYG7gv5A8CUPGUoAvokR yFtO8zz3ByL44Pg9F9Zg2vfyivcuibmK23ypNtHhXoP0KWkaSC2zXvWeJYUGcRSdgfoV+M4Yy 9cPid4uKeLvCc7/fhzkv9tI/lx7xJfu0RLw2w4BZW3jrWps1IgNHWlIa3ozVMlGvfYtYdhT0O z5dOyCGEVJgEje4vU4KtMom9wUzS2IgXt1l1PCfUDJW5l5EAW/SHJzxmFqcZE5cj9EG/kMljO w15zmpNy75aTYHJn0olAqscA== musl-libc doesn't provide , but it defines __WORDSIZE in and . Signed-off-by: J. Neuschäfer --- include/linux/bitops.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.43.0 diff --git a/include/linux/bitops.h b/include/linux/bitops.h index ae33922..4f133ba 100644 --- a/include/linux/bitops.h +++ b/include/linux/bitops.h @@ -1,7 +1,7 @@ #ifndef _KVM_LINUX_BITOPS_H_ #define _KVM_LINUX_BITOPS_H_ -#include +#include #include #include