Skip to contentSkip to conversation

IDE: typo in ide-io.c leads to faulty assignment

PATCH NAK Elias Oltmanns 3 participants 4 messages Nov 27, 2006 libata

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 IDE: typo in ide-io.c leads to faulty assignment

Due to a typo in ide_start_power_step, the result of a function rather than its pointer is assigned to args->handler. The patch applies to 2.6.19-rc6 but the problem exists in the stable branch as well.

---

drivers/ide/ide-io.c +1 -1
index 2614f41..48a249d 100644
@@ -213,7 +213,7 @@ static ide_startstop_t ide_start_power_s
 	case idedisk_pm_idle:		/* Resume step 2 (idle) */
 		args->tfRegister[IDE_COMMAND_OFFSET] = WIN_IDLEIMMEDIATE;
 		args->command_type = IDE_DRIVE_TASK_NO_DATA;
-		args->handler = task_no_data_intr;
+		args->handler = &task_no_data_intr;
 		return do_rw_taskfile(drive, args);
 
 	case ide_pm_restore_dma:	/* Resume step 3 (restore DMA) */
NAK
#1 lore raw
Quoted 2 lines · On Mon, 27 Nov 2006 15:51:33 +0100 Elias Oltmanns <[email protected]> wrote:

Due to a typo in ide_start_power_step, the result of a function rather than its pointer is assigned to args->handler.

NAK

If it was the result of the function it would end with (arguments);

Alan

#2 lore raw
In reply to Elias Oltmanns
Quoted 4 lines · Elias Oltmanns

Due to a typo in ide_start_power_step, the result of a function rather than its pointer is assigned to args->handler. The patch applies to 2.6.19-rc6 but the problem exists in the stable branch as well.

These two lines :

- args->handler = task_no_data_intr;
+ args->handler = &task_no_data_intr;

do the same thing.

Signature · 3 lines
Jesper Juhl <[email protected]>
Don't top-post  http://www.catb.org/~esr/jargon/html/T/top-post.html
Plain text mails only, please      http://www.expita.com/nomime.html
#3 lore raw
Quoted 6 lines · Jesper Juhl

These two lines :

drivers/ide/ide-io.c +1 -1
-		args->handler = task_no_data_intr;
+		args->handler = &task_no_data_intr;

do the same thing.

Thanks for explaining, obviously I got a bit confused.

Sorry for the noise.

Elias