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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Tue, 19 Oct 2010 14:28:17 +0300
From:	Felipe Balbi <balbi@...com>
To:	Felipe Contreras <felipe.contreras@...il.com>
Cc:	"Balbi, Felipe" <balbi@...com>,
	"linux-usb@...r.kernel.org" <linux-usb@...r.kernel.org>,
	linux-main <linux-kernel@...r.kernel.org>,
	Greg KH <greg@...ah.com>
Subject: Re: [PATCH 3/3] drivers: cleanup Kconfig stuff

Hi,

On Tue, Oct 19, 2010 at 05:52:10AM -0500, Felipe Contreras wrote:
>I see, but is it possible that in a board you have the two? If not,

Yes. N900 is one of them :-) It has twl4030-usb for VBUS/ID (id isn't
used) and isp1707 for data lines. It's insane but it's becoming more and
more common to see a HW with two transceivers.

>there must be a way to find the correct transceiver based on the
>configuration. If yes, then there must be a way to select a sensible
>one by default, rather than not having any.

True, but currently that's not the case. We needed a real usb
transceiver "class" (or something else) where you have something like:

struct usb_xceiv {
	struct list_head	head;
	struct device		dev;
	unsigned		capabilities;
	...
};

then you define a transceiver with:

struct usb_xceiv twl4030_usb {
	.name		= "twl4030-usb",
	.capabilities	= USB_XCEIV_CAP_VBUS
		| USB_XCEIV_CAP_DETECT_CHARGER
		| USB_XCEIV_CAP_DATA
		| USB_XCEIV_CAP_WHATEVER_BOARD_NEEDS,
	...
};

capabilities will also be board-specific in most cases, so you could
bring that from platform_data. Currently there's no such thing and I'm
too busy with musb/ehci/ohci/UDC Class to start that.

BTW, this also means the otg_transceiver is a mis-name as a transceiver
is needed in any connection is isn't TLL (transceiver-less link), so you
have usb transceiver in host-only and gadget-only configurations too.

If nobody starts the usb_xceiv class, I'll do it at some point and while
doing that drivers/usb/otg will be renamed to drivers/usb/xceiv together
with all structures and headers. Drivers/usb/otg will hold real otg
peculiarities.

>This way, for example it would be possible to get rid of some lines in
>a minimal n900_defconfig (used in MeeGo[1]), and eventually hopefully
>get rid of all of them (except CONFIG_SND_OMAP_SOC_RX51=y).

true, it would also allow you to have one binary for all your products
:-) althought not so optimal, it's good to ease development/testing.

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