linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] nubus: Set default dma mask for nubus_board devices
@ 2018-06-25 11:46 Finn Thain
  2018-06-28 14:27 ` Christoph Hellwig
  2018-07-02 13:51 ` Geert Uytterhoeven
  0 siblings, 2 replies; 5+ messages in thread
From: Finn Thain @ 2018-06-25 11:46 UTC (permalink / raw)
  To: Geert Uytterhoeven
  Cc: Christoph Hellwig, Greg Kroah-Hartman, linux-m68k, linux-kernel

A 32-bit mask is used by default because a NuBus slot has 32
address/data lines and a NuBus board is free to use all of them.

Cc: Christoph Hellwig <hch@lst.de>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Tested-by: Stan Johnson <userm57@yahoo.com>
Signed-off-by: Finn Thain <fthain@telegraphics.com.au>
---
 drivers/nubus/bus.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/nubus/bus.c b/drivers/nubus/bus.c
index a59b6c4bb5b8..ad3d17c42e23 100644
--- a/drivers/nubus/bus.c
+++ b/drivers/nubus/bus.c
@@ -5,6 +5,7 @@
 // Copyright (C) 2017 Finn Thain
 
 #include <linux/device.h>
+#include <linux/dma-mapping.h>
 #include <linux/list.h>
 #include <linux/nubus.h>
 #include <linux/seq_file.h>
@@ -93,6 +94,8 @@ int nubus_device_register(struct nubus_board *board)
 	board->dev.release = nubus_device_release;
 	board->dev.bus = &nubus_bus_type;
 	dev_set_name(&board->dev, "slot.%X", board->slot);
+	board->dev.dma_mask = &board->dev.coherent_dma_mask;
+	dma_set_mask(&board->dev, DMA_BIT_MASK(32));
 	return device_register(&board->dev);
 }
 
-- 
2.16.4


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] nubus: Set default dma mask for nubus_board devices
  2018-06-25 11:46 [PATCH] nubus: Set default dma mask for nubus_board devices Finn Thain
@ 2018-06-28 14:27 ` Christoph Hellwig
  2018-06-29  4:15   ` Finn Thain
  2018-07-02 13:51 ` Geert Uytterhoeven
  1 sibling, 1 reply; 5+ messages in thread
From: Christoph Hellwig @ 2018-06-28 14:27 UTC (permalink / raw)
  To: Finn Thain
  Cc: Geert Uytterhoeven, Christoph Hellwig, Greg Kroah-Hartman,
	linux-m68k, linux-kernel

On Mon, Jun 25, 2018 at 09:46:11PM +1000, Finn Thain wrote:
> A 32-bit mask is used by default because a NuBus slot has 32
> address/data lines and a NuBus board is free to use all of them.

Looks good:


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] nubus: Set default dma mask for nubus_board devices
  2018-06-28 14:27 ` Christoph Hellwig
@ 2018-06-29  4:15   ` Finn Thain
  2018-06-29  6:59     ` Christoph Hellwig
  0 siblings, 1 reply; 5+ messages in thread
From: Finn Thain @ 2018-06-29  4:15 UTC (permalink / raw)
  To: Christoph Hellwig
  Cc: Geert Uytterhoeven, Greg Kroah-Hartman, linux-m68k, linux-kernel

On Thu, 28 Jun 2018, Christoph Hellwig wrote:

> On Mon, Jun 25, 2018 at 09:46:11PM +1000, Finn Thain wrote:
> > A 32-bit mask is used by default because a NuBus slot has 32 
> > address/data lines and a NuBus board is free to use all of them.
> 
> Looks good:

Thanks for looking it over. But did you forget to include an 
acked-by/reviewed-by tag?

-- 

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] nubus: Set default dma mask for nubus_board devices
  2018-06-29  4:15   ` Finn Thain
@ 2018-06-29  6:59     ` Christoph Hellwig
  0 siblings, 0 replies; 5+ messages in thread
From: Christoph Hellwig @ 2018-06-29  6:59 UTC (permalink / raw)
  To: Finn Thain
  Cc: Christoph Hellwig, Geert Uytterhoeven, Greg Kroah-Hartman,
	linux-m68k, linux-kernel

On Fri, Jun 29, 2018 at 02:15:21PM +1000, Finn Thain wrote:
> On Thu, 28 Jun 2018, Christoph Hellwig wrote:
> 
> > On Mon, Jun 25, 2018 at 09:46:11PM +1000, Finn Thain wrote:
> > > A 32-bit mask is used by default because a NuBus slot has 32 
> > > address/data lines and a NuBus board is free to use all of them.
> > 
> > Looks good:
> 
> Thanks for looking it over. But did you forget to include an 
> acked-by/reviewed-by tag?

Looks like it.

Reviewed-by: Christoph Hellwig <hch@lst.de>

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] nubus: Set default dma mask for nubus_board devices
  2018-06-25 11:46 [PATCH] nubus: Set default dma mask for nubus_board devices Finn Thain
  2018-06-28 14:27 ` Christoph Hellwig
@ 2018-07-02 13:51 ` Geert Uytterhoeven
  1 sibling, 0 replies; 5+ messages in thread
From: Geert Uytterhoeven @ 2018-07-02 13:51 UTC (permalink / raw)
  To: Finn Thain
  Cc: Christoph Hellwig, Greg KH, linux-m68k, Linux Kernel Mailing List

On Mon, Jun 25, 2018 at 1:45 PM Finn Thain <fthain@telegraphics.com.au> wrote:
> A 32-bit mask is used by default because a NuBus slot has 32
> address/data lines and a NuBus board is free to use all of them.
>
> Cc: Christoph Hellwig <hch@lst.de>
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Tested-by: Stan Johnson <userm57@yahoo.com>
> Signed-off-by: Finn Thain <fthain@telegraphics.com.au>

Thanks, applied with Christoph's Rb, and queued for v4.19.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2018-07-02 13:52 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-06-25 11:46 [PATCH] nubus: Set default dma mask for nubus_board devices Finn Thain
2018-06-28 14:27 ` Christoph Hellwig
2018-06-29  4:15   ` Finn Thain
2018-06-29  6:59     ` Christoph Hellwig
2018-07-02 13:51 ` Geert Uytterhoeven

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).