lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <47A845F7.8030102@hvsistemas.es>
Date:	Tue, 05 Feb 2008 12:18:15 +0100
From:	Javier Herrero <jherrero@...istemas.es>
To:	Vojtech Pavlik <vojtech@...e.cz>
CC:	Bryan Wu <bryan.wu@...log.com>,
	Will Newton <will.newton@...il.com>, dmitry.torokhov@...il.com,
	linux-input@...ey.karlin.mff.cuni.cz, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/1 try#2] [INPUT] keypad driver: Added support for	OpenCores
 Keyboard Controller

Dear Vojtech,

I think that a 1:1 mapping between linux keycodes and what keyboard 
sends is right, because the scan code to key code conversion is already 
programmed and done inside the FPGA code.

Best regards,

Javier

Vojtech Pavlik escribió:
> On Thu, Jan 31, 2008 at 01:18:22AM +0800, Bryan Wu wrote:
>
>> +static irqreturn_t opencores_kbd_isr(int irq, void *dev_id)
>> +{
>> +	unsigned char c;
>> +	struct platform_device *pdev = dev_id;
>> +	struct opencores_kbd *opencores_kbd = platform_get_drvdata(pdev);
>> +	struct input_dev *input = opencores_kbd->input;
>> +
>> +	c = readb(opencores_kbd->addr_res->start);
>> +	input_report_key(input, c & 0x7f, c & 0x80 ? 0 : 1);
>> +	input_sync(input);
>> +
>> +	return IRQ_HANDLED;
>> +}
>  
> This looks utterly wrong: It assumes 1:1 mapping between Linux keycodes
> and what the keyboard sends, which I can't believe is the case.
>

-- 
------------------------------------------------------------------------
Javier Herrero                            EMAIL: jherrero@...istemas.com
HV Sistemas S.L.                          PHONE:         +34 949 336 806
Los Charcones, 17A                        FAX:           +34 949 336 792
19170 El Casar - Guadalajara - Spain      WEB: http://www.hvsistemas.com 

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ