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]
Date:	Fri, 25 Apr 2008 17:22:20 +0800
From:	"Yang, Graf" <Graf.Yang@...log.com>
To:	"Alan Cox" <alan@...rguk.ukuu.org.uk>,
	"Linux Kernel Mailing List" <linux-kernel@...r.kernel.org>
Cc:	<graf.yang@...log.com>
Subject: RE: Blackfin Serial Driver: Enable IR function when user application (irattach /dev/ttyBFx -s) call TIOCSETD ioctl with line discipline N_IRDA

Hi, Alan,

Thanks for your suggestions!


Have the tty patches that you mentioned been checked in? Would you please give a link about "the tty patches as they move the tty driver operations out of the tty driver ..."?

I made and tested this patch on 2.6.24.4 kernel, it works, although is ugly.
Blackfin serial driver register as a UART driver, which will call tty_set_operations(...,&uart_ops), while uart_ops hasn't set_ldisc function.
Do you mean I should declare a tty_ops and call tty_set_operations(..., &tty_ops) in bfin_5xx.c to register my set_ldisc?


BRs,
Graf
-----Original Message-----
From: Alan Cox [mailto:alan@...rguk.ukuu.org.uk]
Sent: Fri 4/25/2008 4:50 AM
To: Linux Kernel Mailing List
Cc: graf.yang@...log.com
Subject: Re: Blackfin Serial Driver: Enable IR function when user application (irattach /dev/ttyBFx -s) call TIOCSETD ioctl with line discipline N_IRDA
 
O>     Blackfin Serial Driver: Enable IR function when user application (irattach /dev/ttyBFx -s) call TIOCSETD ioctl with line discipline N_IRDA

>  	if (ret == 0) {
> +		bfin_serial_reg.tty_driver->set_ldisc = bfin_set_ldisc;
>  		ret = platform_driver_register(&bfin_serial_driver);

This will not work when combined with the tty patches as they move the
tty driver operations out of the tty driver and also make them shared and
const. You need to declare two sets of tty_ops and register the correct
one for your device.

Alan
--
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