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, 30 Mar 2012 07:44:09 +0200
From:	Linus Walleij <linus.walleij@...aro.org>
To:	Guennadi Liakhovetski <g.liakhovetski@....de>
Cc:	Vinod Koul <vinod.koul@...el.com>,
	Russell King - ARM Linux <linux@....linux.org.uk>,
	linux-kernel@...r.kernel.org,
	Jassi Brar <jassisinghbrar@...il.com>,
	Magnus Damm <magnus.damm@...il.com>,
	Paul Mundt <lethal@...ux-sh.org>
Subject: Re: [PATCH/RFC] dmaengine: add a slave parameter to __dma_request_channel()

On Fri, Mar 16, 2012 at 3:28 PM, Guennadi Liakhovetski
<g.liakhovetski@....de> wrote:
> On Fri, 16 Mar 2012, Linus Walleij wrote:

>> Oh I was not thinking of relying on config to sort out channels.
>>
>> I was thinking of internalizing the dma_filter_fn and make it an
>> (optional, maybe?) part of dmaengine.
>
> Yessss!!! Let's do that! :-D Now, you're proposing exactly the same, as
> what I was proposing! :-)

No.

> Now you just have to remove the filter function
> parameter from dma_request_channel() - it is anyway the same for all and
> implemented in the dmaengine core - and you get
>
> dma_request_channel(mask, slave_desc)

What is the point of mask on slave channels?
I was more thinking introduce a new call:

dma_request_slave_channel(struct device *dev);

>From this the core looks up a suitable channel for that device.

However you're right (in some later mail) that we need to distinguish
between RX/TX channels at this point, so I can agree we need some
additional parameter, but that should be very abstract, not containing
any custom stuff or any void * or something like that.

If the device and direction is really all we need to distinguish a suitable
channel (which I imagine) the signature may very well be:

dma_request_slave_channel(struct device *dev, enum dma_transfer_direction dir);

But I'm not sure. (Keep beating me about it... but at this point
I think code speaks more than words.)

> which is exactly what I was proposing! :-)

Sorry, not at all AFAICT.

Yours,
Linus Walleij
--
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