From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796142045; b=taozhQLyoSDH/C41jJunMoFGeq6QwmsObTV+QeHbIg5HYrl1sjzI+a6h03JxTrfLSQ9w BrIyu8dvEegyheJns2EiIApordYCnfLDsRxzCzA/QRAioKmKibRKfmLNvpodBheC5srcm 6M7fUn13Qac6ItmUuuxyJ6E45O1xpoH+pSwG5eCC3DtUOp4iMbFhDKm/p2KXjiTXsVb9c hHUuqlqVovbsuZdLWTQ88a/le+eAHBHk8ADx37RdXuHgqbl1rKG68t4iUjQPjzGJycafh xG5a2/r0Sj/MH9HN2mOgaulIzhaH2IGM7MJUCC6B7Uhh4q1MCG+hCGMVvf4zN9cMH1A== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796142045; h=Received:DKIM-Signature:Message-ID:From:Subject:Reply-To:To:Cc: In-Reply-To:References:Content-Type:Content-Transfer-Encoding:Date; bh=8bwzd76QxjmcbgtCvK02gG3+ietbVw9z7xQwtlltmO8=; b=36i8oDNyudSW36vVsfIoyiiyH2T13LrAGEs9KekREV+B+rsrNiNfnWFUMUyIqzpFL2MQ RrJDg+fb+EsLUDpSo4QpSvi8ehz4zmaj/oDk+I0HYHeCUCCIQkxcDSnui9HgPpLs6qjkW l8ZKM8E2nmJDidagcZrW3XM2ME/g9XrcTMlqRCpel8E+iJoWQ4auNmvgjbbB6a1ITkDJ9 W8j92rn2vDh3phcn1mZgo9Ny63cHR0hxiXvi7ec9AFvlxBx0BXZT81IgvPslp5NHocmZ/ 9nBwxGzOVjtCOflRwDhdS1ICNDUvgOU3IQw+jJbgxYToxNsb69QXC5Gu2sYhNfPPUmw== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=j9ZZ8Ix2; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4246F606A337 for ; Tue, 1 Dec 2026 16:20:45 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=j9ZZ8Ix2 Received: by smtp.kernel.org (Postfix) with ESMTPSA id AED741F01DA7; Tue, 1 Dec 2026 16:20:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796142044; bh=8bwzd76QxjmcbgtCvK02gG3+ietbVw9z7xQwtlltmO8=; h=From:Subject:Reply-To:To:Cc:In-Reply-To:References:Date; b=j9ZZ8Ix2qu1m7T1lsBrtPIWziK/DAbgIKOj+76mc5n9Yx2cONWyQWFyX118U9UXYk yS/EfL5iewLSJOA1f6+3ceq2jr2vxFFZ3ewIRyF9bSY7MbvbeFKIfCsNg7FXfgjrGZ A14XyIHM/QEpo0+6SH4XgTjIOUkEUmLRduFFOIFlsmFC1NA+5F0nJ8jAwaRsMrL/2+ 8njEDLIhIdbjt08oeofbM5yA3ZHX1Ko2OT4ehU0MMK3YZ3ONNpvCDELCGv+oMirauf Koi6QFNAy/RE3QvZiQzI+ErZMWguAOStcepHuurmy64ZGFdxxsuoIUuu4CtqaQJwHA Vgs4Ubj7MB03Q== Message-ID: From: sashiko-bot@kernel.org Subject: Re: [PATCH] input: amikbd: fix scancode to key code conversion Reply-To: sashiko-reviews@lists.linux.dev To: "Steffen A. Mork" , linux-input@vger.kernel.org Cc: dmitry.torokhov@gmail.com In-Reply-To: <20261201161232.1165283-1-linux-dev@morknet.de> References: <20261201161232.1165283-1-linux-dev@morknet.de> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Date: Tue, 01 Dec 2026 16:20:44 +0000 X-Mailing-List: linux-input@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list Thank you for your contribution! Sashiko AI review found 2 potential issues to consider: - [Medium] Input: amikbd: build failure when CONFIG_VT=3Dn due to #ifdef CONFIG_VT guard - [Low] Input: amikbd: missing Fixes trailer for commit 5fa28ea42f28 -- commit 7a8125f16e2b07841a12c661705ac3a1a5ade03f Author: Steffen A. Mork > input: amikbd: fix scancode to key code conversion > > Previously the amikbd.c driver passed raw Amiga keyboard scancodes via > input_report_key(). As a result incorrect key codes were transmitted to > libinput and the input event framework, while a remapping was > simultaneously being performed for the VT console via > amikbd_init_console_keymaps(). > > This patch corrects the transmission of these scancodes by ensuring that > the proper Linux key codes are passed to input_report_key() instead. > Consequently, the remapping for the console is no longer necessary. > > The Atari keyboard driver atakbd.c served as a reference for implementing > this fix. > > Tested-by: Steffen A. Mork # native Amiga 2000 > Tested-by: Steffen A. Mork # FS-UAE virtual Amiga = 3000 > Signed-off-by: Steffen A. Mork [Severity: Low] This fixes the raw scancode reporting introduced in commit 5fa28ea42f28. Should this include: Fixes: 5fa28ea42f28 ("[PATCH] m68k: restore amikbd compatibility with 2.4= ") > diff --git a/drivers/input/keyboard/amikbd.c b/drivers/input/keyboard/ami= kbd.c > index ecfae0b0b6aa2..8cfb49e5362d5 100644 > --- a/drivers/input/keyboard/amikbd.c > +++ b/drivers/input/keyboard/amikbd.c > @@ -27,7 +27,7 @@ MODULE_DESCRIPTION("Amiga keyboard driver"); > MODULE_LICENSE("GPL"); > =20 > #ifdef CONFIG_VT > -static unsigned char amikbd_keycode[0x78] __initdata =3D { > +static unsigned short amikbd_keycode[0x78] =3D { > [0] =3D KEY_GRAVE, > [1] =3D KEY_1, > [2] =3D KEY_2, > @@ -126,28 +126,6 @@ static unsigned char amikbd_keycode[0x78] __initdata= =3D { > [103] =3D KEY_RIGHTMETA > }; > =20 > -static void __init amikbd_init_console_keymaps(void) > -{ > - /* We can spare 512 bytes on stack for temp_map in init path. */ > - unsigned short temp_map[NR_KEYS]; > - int i, j; > - > - for (i =3D 0; i < MAX_NR_KEYMAPS; i++) { > - if (!key_maps[i]) > - continue; > - memset(temp_map, 0, sizeof(temp_map)); > - for (j =3D 0; j < 0x78; j++) { > - if (!amikbd_keycode[j]) > - continue; > - temp_map[j] =3D key_maps[i][amikbd_keycode[j]]; > - } > - for (j =3D 0; j < NR_KEYS; j++) { > - if (!temp_map[j]) > - temp_map[j] =3D 0xf200; > - } > - memcpy(key_maps[i], temp_map, sizeof(temp_map)); > - } > -} > #else /* !CONFIG_VT */ > static inline void amikbd_init_console_keymaps(void) {} > #endif /* !CONFIG_VT */ [Severity: Medium] Does this fail to build when CONFIG_VT is disabled? amikbd_keycode[] is now referenced unconditionally in amikbd_interrupt() and amikbd_probe(), so the #ifdef CONFIG_VT guard and the unused amikbd_init_console_keymaps() stub in the #else branch need to be removed as well. --=20 Sashiko AI review =C2=B7 https://sashiko.dev/#/patchset/20261201161232.1165= 283-1-linux-dev@morknet.de?part=3D1