linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/6] icside: fix ->speedproc to return on unsupported modes
@ 2007-07-11  0:00 Bartlomiej Zolnierkiewicz
  2007-07-11 19:07 ` Sergei Shtylyov
  0 siblings, 1 reply; 16+ messages in thread
From: Bartlomiej Zolnierkiewicz @ 2007-07-11  0:00 UTC (permalink / raw)
  To: linux-ide; +Cc: Russell King


icside_set_speed() happily accepts unsupported transfer modes which
results in drive->drive_data being set to the maximum value (480)
and drive->current_speed being set to the unsupported transfer mode.

Fix it.

Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Cc: Russell King <rmk@arm.linux.org.uk>
---
 drivers/ide/arm/icside.c |    2 ++
 1 file changed, 2 insertions(+)

Index: b/drivers/ide/arm/icside.c
===================================================================
--- a/drivers/ide/arm/icside.c
+++ b/drivers/ide/arm/icside.c
@@ -272,6 +272,8 @@ static int icside_set_speed(ide_drive_t 
 	case XFER_SW_DMA_0:
 		cycle_time = 480;
 		break;
+	default:
+		return 1;
 	}
 
 	/*

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

end of thread, other threads:[~2007-07-24 22:30 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-07-11  0:00 [PATCH 1/6] icside: fix ->speedproc to return on unsupported modes Bartlomiej Zolnierkiewicz
2007-07-11 19:07 ` Sergei Shtylyov
2007-07-11 19:56   ` Russell King
2007-07-11 20:15     ` Sergei Shtylyov
2007-07-11 21:21     ` Bartlomiej Zolnierkiewicz
2007-07-12 19:23       ` Sergei Shtylyov
2007-07-13 21:02         ` Bartlomiej Zolnierkiewicz
2007-07-13 21:39           ` Russell King
2007-07-13 22:49             ` Bartlomiej Zolnierkiewicz
2007-07-13 23:15             ` Alan Cox
2007-07-13 23:20               ` Russell King
2007-07-13 23:54                 ` Alan Cox
2007-07-14 19:15                   ` Russell King
2007-07-24 22:30                     ` Russell King
2007-07-14 17:42           ` Sergei Shtylyov
2007-07-18 21:21             ` Bartlomiej Zolnierkiewicz

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).