Remove newline from pci MODALIAS variable
PATCH 1/1 Remove newline from pci MODALIAS variable
Hi Greg,
the pci core sends out a hotplug event variable MODALIAS with a trailing newline. This is inconsistent with all other event variables and breaks some hotplug tools. This patch removes the said newline.
Please apply.
Cheers,
Hannes
Signature · 4 lines
Dr. Hannes Reinecke [email protected] SuSE Linux AG S390 & zSeries Maxfeldstraße 5 +49 911 74053 688 90409 Nürnberg http://www.suse.de
From: Hannes Reinecke <[email protected]>
Subject: Remove newline from MODALIAS
PCI hotplug events carry a newline in the MODALIAS variable. This confuses scripts unneccesarily.
drivers/pci/hotplug.c renamed from drivers/pci/hotplug.c.orig +1 -1
@@ -54,7 +54,7 @@ int pci_hotplug (struct device *dev, cha envp[i++] = scratch; length += scnprintf (scratch, buffer_size - length, - "MODALIAS=pci:v%08Xd%08Xsv%08Xsd%08Xbc%02Xsc%02Xi%02x\n", + "MODALIAS=pci:v%08Xd%08Xsv%08Xsd%08Xbc%02Xsc%02Xi%02x", pdev->vendor, pdev->device, pdev->subsystem_vendor, pdev->subsystem_device, (u8)(pdev->class >> 16), (u8)(pdev->class >> 8),