Skip to content

Commit

Permalink
atari_scsi: Convert to platform device
Browse files Browse the repository at this point in the history
Convert atari_scsi to platform device and eliminate scsi_register().

Validate __setup options later on so that module options are checked as well.

Remove the comment about the scsi mid-layer disabling the host irq as it
is no longer true (AFAICT). Also remove the obsolete slow interrupt stuff
(IRQ_TYPE_SLOW == 0 anyway).

Signed-off-by: Finn Thain <fthain@telegraphics.com.au>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Tested-by: Michael Schmitz <schmitzmic@gmail.com>
Acked-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Christoph Hellwig <hch@lst.de>
  • Loading branch information
Finn Thain authored and Christoph Hellwig committed Nov 20, 2014
1 parent 16b29e7 commit 3ff228a
Show file tree
Hide file tree
Showing 3 changed files with 237 additions and 231 deletions.
27 changes: 27 additions & 0 deletions arch/m68k/atari/config.c
Original file line number Diff line number Diff line change
Expand Up @@ -858,6 +858,24 @@ static struct platform_device *atari_netusbee_devices[] __initdata = {
};
#endif /* CONFIG_ATARI_ETHERNEC */

#ifdef CONFIG_ATARI_SCSI
static const struct resource atari_scsi_st_rsrc[] __initconst = {
{
.flags = IORESOURCE_IRQ,
.start = IRQ_MFP_FSCSI,
.end = IRQ_MFP_FSCSI,
},
};

static const struct resource atari_scsi_tt_rsrc[] __initconst = {
{
.flags = IORESOURCE_IRQ,
.start = IRQ_TT_MFP_SCSI,
.end = IRQ_TT_MFP_SCSI,
},
};
#endif

int __init atari_platform_init(void)
{
int rv = 0;
Expand Down Expand Up @@ -892,6 +910,15 @@ int __init atari_platform_init(void)
}
#endif

#ifdef CONFIG_ATARI_SCSI
if (ATARIHW_PRESENT(ST_SCSI))
platform_device_register_simple("atari_scsi", -1,
atari_scsi_st_rsrc, ARRAY_SIZE(atari_scsi_st_rsrc));
else if (ATARIHW_PRESENT(TT_SCSI))
platform_device_register_simple("atari_scsi", -1,
atari_scsi_tt_rsrc, ARRAY_SIZE(atari_scsi_tt_rsrc));
#endif

return rv;
}

Expand Down
Loading

0 comments on commit 3ff228a

Please sign in to comment.