Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 53f46542 authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman
Browse files

[PATCH] Driver Core: fix up all callers of class_device_create()



The previous patch adding the ability to nest struct class_device
changed the paramaters to the call class_device_create().  This patch
fixes up all in-kernel users of the function.

Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 51d172d5
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -163,7 +163,7 @@ static int cpuid_class_device_create(int i)
	int err = 0;
	struct class_device *class_err;

	class_err = class_device_create(cpuid_class, MKDEV(CPUID_MAJOR, i), NULL, "cpu%d",i);
	class_err = class_device_create(cpuid_class, NULL, MKDEV(CPUID_MAJOR, i), NULL, "cpu%d",i);
	if (IS_ERR(class_err))
		err = PTR_ERR(class_err);
	return err;
+1 −1
Original line number Diff line number Diff line
@@ -246,7 +246,7 @@ static int msr_class_device_create(int i)
	int err = 0;
	struct class_device *class_err;

	class_err = class_device_create(msr_class, MKDEV(MSR_MAJOR, i), NULL, "msr%d",i);
	class_err = class_device_create(msr_class, NULL, MKDEV(MSR_MAJOR, i), NULL, "msr%d",i);
	if (IS_ERR(class_err)) 
		err = PTR_ERR(class_err);
	return err;
+1 −1
Original line number Diff line number Diff line
@@ -224,7 +224,7 @@ aoechr_init(void)
		return PTR_ERR(aoe_class);
	}
	for (i = 0; i < ARRAY_SIZE(chardevs); ++i)
		class_device_create(aoe_class,
		class_device_create(aoe_class, NULL,
					MKDEV(AOE_MAJOR, chardevs[i].minor),
					NULL, chardevs[i].name);

+1 −1
Original line number Diff line number Diff line
@@ -674,7 +674,7 @@ static int __init pg_init(void)
	for (unit = 0; unit < PG_UNITS; unit++) {
		struct pg *dev = &devices[unit];
		if (dev->present) {
			class_device_create(pg_class, MKDEV(major, unit),
			class_device_create(pg_class, NULL, MKDEV(major, unit),
					NULL, "pg%u", unit);
			err = devfs_mk_cdev(MKDEV(major, unit),
				      S_IFCHR | S_IRUSR | S_IWUSR, "pg/%u",
+2 −2
Original line number Diff line number Diff line
@@ -971,7 +971,7 @@ static int __init pt_init(void)
	devfs_mk_dir("pt");
	for (unit = 0; unit < PT_UNITS; unit++)
		if (pt[unit].present) {
			class_device_create(pt_class, MKDEV(major, unit),
			class_device_create(pt_class, NULL, MKDEV(major, unit),
					NULL, "pt%d", unit);
			err = devfs_mk_cdev(MKDEV(major, unit),
				      S_IFCHR | S_IRUSR | S_IWUSR,
@@ -980,7 +980,7 @@ static int __init pt_init(void)
				class_device_destroy(pt_class, MKDEV(major, unit));
				goto out_class;
			}
			class_device_create(pt_class, MKDEV(major, unit + 128),
			class_device_create(pt_class, NULL, MKDEV(major, unit + 128),
					NULL, "pt%dn", unit);
			err = devfs_mk_cdev(MKDEV(major, unit + 128),
				      S_IFCHR | S_IRUSR | S_IWUSR,
Loading