Skip to contentSkip to conversation

Cleanup & (partly?) support swsusp for aic7xxx

PATCH Pavel Machek 2 participants 2 messages Apr 5, 2004

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

Hi!

This kills checks for kernels older than 2.5.60, and marks threads as needed for suspend (which they probably are).

Pavel

drivers/scsi/aic7xxx/aic79xx_osm.c renamed from linux/drivers/scsi/aic7xxx/aic79xx_osm.c +1 -10
@@ -2581,17 +2581,8 @@
 	 * Complete thread creation.
 	 */
 	lock_kernel();
-#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,60)
-	/*
-	 * Don't care about any signals.
-	 */
-	siginitsetinv(&current->blocked, 0);
-
-	daemonize();
-	sprintf(current->comm, "ahd_dv_%d", ahd->unit);
-#else
 	daemonize("ahd_dv_%d", ahd->unit);
-#endif
+	current->flags |= PF_IOTHREAD;
 	unlock_kernel();
 
 	while (1) {
drivers/scsi/aic7xxx/aic7xxx_osm.c renamed from linux/drivers/scsi/aic7xxx/aic7xxx_osm.c +1 -10
@@ -2286,17 +2286,8 @@
 	 * Complete thread creation.
 	 */
 	lock_kernel();
-#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0)
-	/*
-	 * Don't care about any signals.
-	 */
-	siginitsetinv(&current->blocked, 0);
-
-	daemonize();
-	sprintf(current->comm, "ahc_dv_%d", ahc->unit);
-#else
 	daemonize("ahc_dv_%d", ahc->unit);
-#endif
+	current->flags |= PF_IOTHREAD;
 	unlock_kernel();
 
 	while (1) {
Signature · 2 lines
When do you have a heart between your knees?
[Johanka's followup: and *two* hearts?]
#1 lore raw
Quoted 3 lines · Pavel Machek

This kills checks for kernels older than 2.5.60, and marks threads as needed for suspend (which they probably are).

This driver supports 2.4.x kernels from the same codebase, so this will be an unpopular patch.

I'll move the PF_IOTHREAD inside the 2.6-specific leg of the ifdef.