diff options
author | Adrian Schmutzler <freifunk@adrianschmutzler.de> | 2020-02-08 21:58:55 +0100 |
---|---|---|
committer | Adrian Schmutzler <freifunk@adrianschmutzler.de> | 2020-02-14 14:10:51 +0100 |
commit | 7d7aa2fd924c27829ec25f825481554dd81bce97 (patch) | |
tree | 658b87b89331670266163e522ea5fb52535633cb /target/linux/brcm2708/patches-4.19/950-0635-driver-char-rpivid-also-support-legacy-name.patch | |
parent | e7bfda2c243e66a75ff966ba04c28b1590b5d24c (diff) | |
download | upstream-7d7aa2fd924c27829ec25f825481554dd81bce97.tar.gz upstream-7d7aa2fd924c27829ec25f825481554dd81bce97.tar.bz2 upstream-7d7aa2fd924c27829ec25f825481554dd81bce97.zip |
brcm2708: rename target to bcm27xx
This change makes the names of Broadcom targets consistent by using
the common notation based on SoC/CPU ID (which is used internally
anyway), bcmXXXX instead of brcmXXXX.
This is even used for target TITLE in make menuconfig already,
only the short target name used brcm so far.
Despite, since subtargets range from bcm2708 to bcm2711, it seems
appropriate to use bcm27xx instead of bcm2708 (again, as already done
for BOARDNAME).
This also renames the packages brcm2708-userland and brcm2708-gpu-fw.
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
Acked-by: Álvaro Fernández Rojas <noltari@gmail.com>
Diffstat (limited to 'target/linux/brcm2708/patches-4.19/950-0635-driver-char-rpivid-also-support-legacy-name.patch')
-rw-r--r-- | target/linux/brcm2708/patches-4.19/950-0635-driver-char-rpivid-also-support-legacy-name.patch | 71 |
1 files changed, 0 insertions, 71 deletions
diff --git a/target/linux/brcm2708/patches-4.19/950-0635-driver-char-rpivid-also-support-legacy-name.patch b/target/linux/brcm2708/patches-4.19/950-0635-driver-char-rpivid-also-support-legacy-name.patch deleted file mode 100644 index 34dd24208c..0000000000 --- a/target/linux/brcm2708/patches-4.19/950-0635-driver-char-rpivid-also-support-legacy-name.patch +++ /dev/null @@ -1,71 +0,0 @@ -From 80c20ff00542b050733780ae6088e50663ee8d78 Mon Sep 17 00:00:00 2001 -From: Phil Elwell <phil@raspberrypi.org> -Date: Mon, 29 Jul 2019 12:03:21 +0100 -Subject: [PATCH] driver: char: rpivid - also support legacy name - -Provide transitional support for the previous names of -the character devices. - -Signed-off-by: Phil Elwell <phil@raspberrypi.org> ---- - drivers/char/broadcom/rpivid-mem.c | 22 ++++++++++++++++++---- - 1 file changed, 18 insertions(+), 4 deletions(-) - ---- a/drivers/char/broadcom/rpivid-mem.c -+++ b/drivers/char/broadcom/rpivid-mem.c -@@ -66,7 +66,7 @@ static int rpivid_mem_open(struct inode - int dev = iminor(inode); - int ret = 0; - struct rpivid_mem_priv *priv; -- if (dev != DEVICE_MINOR) -+ if (dev != DEVICE_MINOR && dev != DEVICE_MINOR + 1) - ret = -ENXIO; - - priv = container_of(inode->i_cdev, struct rpivid_mem_priv, -@@ -82,7 +82,7 @@ static int rpivid_mem_release(struct ino - int dev = iminor(inode); - int ret = 0; - -- if (dev != DEVICE_MINOR) -+ if (dev != DEVICE_MINOR && dev != DEVICE_MINOR + 1) - ret = -ENXIO; - - return ret; -@@ -167,14 +167,14 @@ static int rpivid_mem_probe(struct platf - /* Create character device entries */ - - err = alloc_chrdev_region(&priv->devid, -- DEVICE_MINOR, 1, priv->name); -+ DEVICE_MINOR, 2, priv->name); - if (err != 0) { - dev_err(priv->dev, "unable to allocate device number"); - goto failed_alloc_chrdev; - } - cdev_init(&priv->rpivid_mem_cdev, &rpivid_mem_fops); - priv->rpivid_mem_cdev.owner = THIS_MODULE; -- err = cdev_add(&priv->rpivid_mem_cdev, priv->devid, 1); -+ err = cdev_add(&priv->rpivid_mem_cdev, priv->devid, 2); - if (err != 0) { - dev_err(priv->dev, "unable to register device"); - goto failed_cdev_add; -@@ -194,6 +194,20 @@ static int rpivid_mem_probe(struct platf - if (IS_ERR(ptr_err)) - goto failed_device_create; - -+ /* Legacy alias */ -+ { -+ char *oldname = kstrdup(priv->name, GFP_KERNEL); -+ -+ oldname[1] = 'a'; -+ oldname[2] = 'r'; -+ oldname[3] = 'g'; -+ oldname[4] = 'o'; -+ oldname[5] = 'n'; -+ (void)device_create(priv->class, NULL, priv->devid + 1, NULL, -+ oldname + 1); -+ kfree(oldname); -+ } -+ - dev_info(priv->dev, "%s initialised: Registers at 0x%08lx length 0x%08lx", - priv->name, priv->regs_phys, priv->mem_window_len); - |