public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Ian Abbott <abbotti@mev.co.uk>
To: H Hartley Sweeten <hartleys@visionengravers.com>
Cc: Geert Uytterhoeven <geert@linux-m68k.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"devel@driverdev.osuosl.org" <devel@driverdev.osuosl.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Ian Abbott <ian.abbott@mev.co.uk>
Subject: Re: [PATCH 12/12] staging: COMEDI should depend on HAS_DMA
Date: Fri, 10 May 2013 11:02:03 +0100	[thread overview]
Message-ID: <518CC59B.3080208@mev.co.uk> (raw)
In-Reply-To: <ADE657CA350FB648AAC2C43247A983F0021D46AC8173@AUSP01VMBX24.collaborationhost.net>

On 2013-05-09 22:33, H Hartley Sweeten wrote:
> On Thursday, May 09, 2013 2:05 PM, Geert Uytterhoeven wrote:
>> If NO_DMA=y:
>>
>> ERROR: "dma_free_coherent" [drivers/staging/comedi/comedi.ko] undefined!
>> ERROR: "dma_alloc_coherent" [drivers/staging/comedi/comedi.ko] undefined!
>>
>> Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
>> Cc: Ian Abbott <abbotti@mev.co.uk>
>> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
>> Cc: devel@driverdev.osuosl.org
>
> Grr..
>
> The error appears to be caused by the dma alloc/free in comedi_buf.c.
> These only happen if the (s->async_dma_dir != DMA_NONE). The comedi
> core defaults the async_dma_dir to DMA_NONE. The only comedi drivers
> that set it are ni_660x, ni_mio_common, and ni_pcidio.
>
> The mite driver also has a dma_alloc/free.
>
> Ian, can you think of a better solution than just making comedi depend on HAS_DMA?

The only alternative I can think of is to change comedi_buf.c to only 
compile in the functions if CONFIG_HAS_DMA is defined and to make the 
following config options depend on HAS_DMA:

COMEDI_NI_6527
COMEDI_NI_65XX
COMEDI_NI_660X
COMEDI_NI_670X
COMEDI_NI_LABPC_PCI
COMEDI_NI_PCIDIO
COMEDI_NI_PCIMIO
COMEDI_MITE
COMEDI_NI_TIOCMD

-- 
-=( Ian Abbott @ MEV Ltd.    E-mail: <abbotti@mev.co.uk>        )=-
-=( Tel: +44 (0)161 477 1898   FAX: +44 (0)161 718 3587         )=-

  reply	other threads:[~2013-05-10 10:02 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-09 21:04 [PATCH 01/12] fbdev: FB_GOLDFISH should depend on HAS_DMA Geert Uytterhoeven
2013-05-09 21:04 ` [PATCH 02/12] [SCSI] SCSI_UFSHCD should depend on SCSI_DMA Geert Uytterhoeven
2013-05-09 21:04 ` [PATCH 03/12] net/ethernet: NET_CALXEDA_XGMAC should depend on HAS_DMA Geert Uytterhoeven
2013-05-11 23:28   ` David Miller
2013-05-09 21:04 ` [PATCH 04/12] net/ethernet: STMMAC_ETH " Geert Uytterhoeven
2013-05-11 23:28   ` David Miller
2013-05-09 21:04 ` [PATCH 05/12] net/wireless: ATH9K " Geert Uytterhoeven
2013-05-11 23:29   ` David Miller
2013-05-09 21:04 ` [PATCH 06/12] mtd: MTD_NAND_DENALI " Geert Uytterhoeven
2013-05-09 21:04 ` [PATCH 07/12] net/ethernet: ARM_AT91_ETHER " Geert Uytterhoeven
2013-05-10  8:22   ` Nicolas Ferre
2013-05-11 23:29   ` David Miller
2013-05-09 21:04 ` [PATCH 08/12] net/ethernet: MACB " Geert Uytterhoeven
2013-05-10  8:22   ` Nicolas Ferre
2013-05-11 23:29   ` David Miller
2013-05-09 21:04 ` [PATCH 09/12] uio: UIO_DMEM_GENIRQ " Geert Uytterhoeven
2013-05-09 21:04 ` [PATCH 10/12] caif: CAIF_VIRTIO " Geert Uytterhoeven
2013-05-11 23:29   ` David Miller
2013-05-09 21:04 ` [PATCH 11/12] drm: DRM " Geert Uytterhoeven
2013-05-09 21:04 ` [PATCH 12/12] staging: COMEDI " Geert Uytterhoeven
2013-05-09 21:33   ` H Hartley Sweeten
2013-05-10 10:02     ` Ian Abbott [this message]
2013-05-10 12:07       ` Ian Abbott

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=518CC59B.3080208@mev.co.uk \
    --to=abbotti@mev.co.uk \
    --cc=devel@driverdev.osuosl.org \
    --cc=geert@linux-m68k.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=hartleys@visionengravers.com \
    --cc=ian.abbott@mev.co.uk \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox