generic: 6.12: manually rebuilding backport patches
authorMieczyslaw Nalewaj <namiltd@yahoo.com>
Mon, 9 Dec 2024 19:40:23 +0000 (20:40 +0100)
committerZoltan HERPAI <wigyori@uid0.hu>
Tue, 17 Dec 2024 22:28:09 +0000 (23:28 +0100)
Manually rebuilding backport patches:
 - 410-v6.13-01-block-add-support-for-defining-read-only-partitions.patch
 - 839-v6.13-net-phy-aquantia-allow-forcing-order-of-MDI-pairs.patch
 - 901-v6.13-net-dsa-mv88e6xxx-Support-LED-control.patch

All other patches automatically rebased.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
target/linux/generic/backport-6.12/410-v6.13-01-block-add-support-for-defining-read-only-partitions.patch
target/linux/generic/backport-6.12/410-v6.13-03-block-introduce-add_disk_fwnode.patch
target/linux/generic/backport-6.12/410-v6.13-04-mmc-block-attach-partitions-fwnode-if-found-in-mmc-c.patch
target/linux/generic/backport-6.12/839-v6.13-net-phy-aquantia-allow-forcing-order-of-MDI-pairs.patch
target/linux/generic/backport-6.12/840-v6.13-net-phy-aquantia-fix-return-value-check-in-aqr107_co.patch
target/linux/generic/backport-6.12/841-v6.13-net-phy-support-active-high-property-for-PHY-LEDs.patch
target/linux/generic/backport-6.12/842-v6.13-net-phy-aquantia-correctly-describe-LED-polarity-ove.patch
target/linux/generic/backport-6.12/843-v6.13-net-phy-mxl-gpy-add-basic-LED-support.patch
target/linux/generic/backport-6.12/844-v6.13-net-phy-mxl-gpy-add-missing-support-for-TRIGGER_NETD.patch
target/linux/generic/backport-6.12/845-v6.13-net-phy-mxl-gpy-correctly-describe-LED-polarity.patch
target/linux/generic/backport-6.12/901-v6.13-net-dsa-mv88e6xxx-Support-LED-control.patch

index fabf16a2e631359d0cbed0995c592211f15e2d89..ffd65253a5c629c7879a3b9c5ef61d94aab4cee0 100644 (file)
@@ -19,7 +19,7 @@ Signed-off-by: Jens Axboe <axboe@kernel.dk>
 
 --- a/block/blk.h
 +++ b/block/blk.h
-@@ -424,6 +424,7 @@ void blk_free_ext_minor(unsigned int min
+@@ -564,6 +564,7 @@ void blk_free_ext_minor(unsigned int min
  #define ADDPART_FLAG_NONE     0
  #define ADDPART_FLAG_RAID     1
  #define ADDPART_FLAG_WHOLEDISK        2
@@ -41,12 +41,12 @@ Signed-off-by: Jens Axboe <axboe@kernel.dk>
        strscpy(info->volname, subpart->name, sizeof(info->volname));
 --- a/block/partitions/core.c
 +++ b/block/partitions/core.c
-@@ -392,6 +392,9 @@ static struct block_device *add_partitio
+@@ -373,6 +373,9 @@ static struct block_device *add_partitio
                        goto out_del;
        }
  
 +      if (flags & ADDPART_FLAG_READONLY)
-+              bdev->bd_read_only = true;
++              bdev_set_flag(bdev, BD_READ_ONLY);
 +
        /* everything is up and running, commence */
        err = xa_insert(&disk->part_tbl, partno, bdev, GFP_KERNEL);
index 41b51ab215c0894898aceb87943b8f4be12ce1ad..772584a9fd12912e7fcee77b0b175d055b7df39b 100644 (file)
@@ -48,7 +48,7 @@ Signed-off-by: Jens Axboe <axboe@kernel.dk>
  
  {
        struct device *ddev = disk_to_dev(disk);
-@@ -451,6 +453,8 @@ int __must_check device_add_disk(struct
+@@ -452,6 +454,8 @@ int __must_check device_add_disk(struct
        ddev->parent = parent;
        ddev->groups = groups;
        dev_set_name(ddev, "%s", disk->disk_name);
@@ -57,7 +57,7 @@ Signed-off-by: Jens Axboe <axboe@kernel.dk>
        if (!(disk->flags & GENHD_FL_HIDDEN))
                ddev->devt = MKDEV(disk->major, disk->first_minor);
        ret = device_add(ddev);
-@@ -552,6 +556,22 @@ out_exit_elevator:
+@@ -553,6 +557,22 @@ out_exit_elevator:
                elevator_exit(disk->queue);
        return ret;
  }
@@ -82,7 +82,7 @@ Signed-off-by: Jens Axboe <axboe@kernel.dk>
  static void blk_report_disk_dead(struct gendisk *disk, bool surprise)
 --- a/include/linux/blkdev.h
 +++ b/include/linux/blkdev.h
-@@ -741,6 +741,9 @@ static inline unsigned int blk_queue_dep
+@@ -735,6 +735,9 @@ static inline unsigned int blk_queue_dep
  #define for_each_bio(_bio)            \
        for (; _bio; _bio = _bio->bi_next)
  
index cf0d18cf06344df977cb3eff70c1f6e3937c1f3a..0bdeaa85e4c27322e27169cfab554e734f65a508 100644 (file)
@@ -26,7 +26,7 @@ Signed-off-by: Jens Axboe <axboe@kernel.dk>
 
 --- a/drivers/mmc/core/block.c
 +++ b/drivers/mmc/core/block.c
-@@ -2455,6 +2455,56 @@ static inline int mmc_blk_readonly(struc
+@@ -2517,6 +2517,56 @@ static inline int mmc_blk_readonly(struc
               !(card->csd.cmdclass & CCC_BLOCK_WRITE);
  }
  
@@ -83,7 +83,7 @@ Signed-off-by: Jens Axboe <axboe@kernel.dk>
  static struct mmc_blk_data *mmc_blk_alloc_req(struct mmc_card *card,
                                              struct device *parent,
                                              sector_t size,
-@@ -2463,6 +2513,7 @@ static struct mmc_blk_data *mmc_blk_allo
+@@ -2525,6 +2575,7 @@ static struct mmc_blk_data *mmc_blk_allo
                                              int area_type,
                                              unsigned int part_type)
  {
@@ -91,7 +91,7 @@ Signed-off-by: Jens Axboe <axboe@kernel.dk>
        struct mmc_blk_data *md;
        int devidx, ret;
        char cap_str[10];
-@@ -2568,7 +2619,9 @@ static struct mmc_blk_data *mmc_blk_allo
+@@ -2626,7 +2677,9 @@ static struct mmc_blk_data *mmc_blk_allo
        /* used in ->open, must be set before add_disk: */
        if (area_type == MMC_BLK_DATA_AREA_MAIN)
                dev_set_drvdata(&card->dev, md);
index c1655ce71e74dbe8f668d574725f920e66776b91..aabaa33e2cc0b61cf7b782d5b412702ac8b01ae6 100644 (file)
@@ -52,7 +52,7 @@ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
  #include <linux/phy.h>
  
  #include "aquantia.h"
-@@ -70,6 +71,11 @@
+@@ -71,6 +72,11 @@
  #define MDIO_AN_TX_VEND_INT_MASK2             0xd401
  #define MDIO_AN_TX_VEND_INT_MASK2_LINK                BIT(0)
  
@@ -64,8 +64,8 @@ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
  #define MDIO_AN_RX_LP_STAT1                   0xe820
  #define MDIO_AN_RX_LP_STAT1_1000BASET_FULL    BIT(15)
  #define MDIO_AN_RX_LP_STAT1_1000BASET_HALF    BIT(14)
-@@ -497,6 +503,29 @@ static int aqr107_wait_processor_intensi
-       return 0;
+@@ -485,6 +491,29 @@ static void aqr107_chip_info(struct phy_
+                  fw_major, fw_minor, build_id, prov_id);
  }
  
 +static int aqr107_config_mdi(struct phy_device *phydev)
@@ -94,7 +94,7 @@ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
  static int aqr107_config_init(struct phy_device *phydev)
  {
        struct aqr107_priv *priv = phydev->priv;
-@@ -535,6 +564,10 @@ static int aqr107_config_init(struct phy
+@@ -514,6 +543,10 @@ static int aqr107_config_init(struct phy
        if (ret)
                return ret;
  
index 73be78a0582ebc9cf40895c6586f3df812382f03..565edbd388d8532f91daf67ddb3268eaac0b43cc 100644 (file)
@@ -20,7 +20,7 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org>
 
 --- a/drivers/net/phy/aquantia/aquantia_main.c
 +++ b/drivers/net/phy/aquantia/aquantia_main.c
-@@ -512,7 +512,7 @@ static int aqr107_config_mdi(struct phy_
+@@ -500,7 +500,7 @@ static int aqr107_config_mdi(struct phy_
        ret = of_property_read_u32(np, "marvell,mdi-cfg-order", &mdi_conf);
  
        /* Do nothing in case property "marvell,mdi-cfg-order" is not present */
index 729a31562337dca01bd8126112ba4eda283c316c..7781aa2c49d37deef7d463541d505f21dc8c13ee 100644 (file)
@@ -19,7 +19,7 @@ Signed-off-by: Paolo Abeni <pabeni@redhat.com>
 
 --- a/drivers/net/phy/phy_device.c
 +++ b/drivers/net/phy/phy_device.c
-@@ -3220,11 +3220,17 @@ static int of_phy_led(struct phy_device
+@@ -3358,11 +3358,17 @@ static int of_phy_led(struct phy_device
        if (index > U8_MAX)
                return -EINVAL;
  
@@ -39,7 +39,7 @@ Signed-off-by: Paolo Abeni <pabeni@redhat.com>
                if (!phydev->drv->led_polarity_set)
 --- a/include/linux/phy.h
 +++ b/include/linux/phy.h
-@@ -872,8 +872,9 @@ struct phy_led {
+@@ -877,8 +877,9 @@ struct phy_plca_status {
  
  /* Modes for PHY LED configuration */
  enum phy_led_modes {
index f26bb829e45c79c9f9276964c387e211b7628c16..155f796f8c09b9b7149ff0645e73dca0f5e3f46d 100644 (file)
@@ -23,7 +23,7 @@ Signed-off-by: Paolo Abeni <pabeni@redhat.com>
 
 --- a/drivers/net/phy/aquantia/aquantia.h
 +++ b/drivers/net/phy/aquantia/aquantia.h
-@@ -169,6 +169,7 @@ static const struct aqr107_hw_stat aqr10
+@@ -177,6 +177,7 @@ static const struct aqr107_hw_stat aqr10
  struct aqr107_priv {
        u64 sgmii_stats[AQR107_SGMII_STAT_SZ];
        unsigned long leds_active_low;
@@ -80,7 +80,7 @@ Signed-off-by: Paolo Abeni <pabeni@redhat.com>
  }
 --- a/drivers/net/phy/aquantia/aquantia_main.c
 +++ b/drivers/net/phy/aquantia/aquantia_main.c
-@@ -529,7 +529,7 @@ static int aqr107_config_mdi(struct phy_
+@@ -517,7 +517,7 @@ static int aqr107_config_mdi(struct phy_
  static int aqr107_config_init(struct phy_device *phydev)
  {
        struct aqr107_priv *priv = phydev->priv;
@@ -89,7 +89,7 @@ Signed-off-by: Paolo Abeni <pabeni@redhat.com>
        int ret;
  
        /* Check that the PHY interface type is compatible */
-@@ -569,8 +569,14 @@ static int aqr107_config_init(struct phy
+@@ -548,8 +548,14 @@ static int aqr107_config_init(struct phy
                return ret;
  
        /* Restore LED polarity state after reset */
index 2ceaa0ad3d0b20ce821e038707fcb6fbe6b88888..c785f8a98a81498775792311936be4183b13cbb9 100644 (file)
@@ -65,7 +65,7 @@ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
  /* SGMII */
  #define VSPEC1_SGMII_CTRL     0x08
  #define VSPEC1_SGMII_CTRL_ANEN        BIT(12)         /* Aneg enable */
-@@ -827,6 +850,156 @@ static int gpy115_loopback(struct phy_de
+@@ -835,6 +858,156 @@ static int gpy115_loopback(struct phy_de
        return genphy_soft_reset(phydev);
  }
  
@@ -222,7 +222,7 @@ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
  static struct phy_driver gpy_drivers[] = {
        {
                PHY_ID_MATCH_MODEL(PHY_ID_GPY2xx),
-@@ -844,6 +1017,11 @@ static struct phy_driver gpy_drivers[] =
+@@ -852,6 +1025,11 @@ static struct phy_driver gpy_drivers[] =
                .set_wol        = gpy_set_wol,
                .get_wol        = gpy_get_wol,
                .set_loopback   = gpy_loopback,
@@ -234,7 +234,7 @@ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
        },
        {
                .phy_id         = PHY_ID_GPY115B,
-@@ -862,6 +1040,11 @@ static struct phy_driver gpy_drivers[] =
+@@ -870,6 +1048,11 @@ static struct phy_driver gpy_drivers[] =
                .set_wol        = gpy_set_wol,
                .get_wol        = gpy_get_wol,
                .set_loopback   = gpy115_loopback,
@@ -246,7 +246,7 @@ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
        },
        {
                PHY_ID_MATCH_MODEL(PHY_ID_GPY115C),
-@@ -879,6 +1062,11 @@ static struct phy_driver gpy_drivers[] =
+@@ -887,6 +1070,11 @@ static struct phy_driver gpy_drivers[] =
                .set_wol        = gpy_set_wol,
                .get_wol        = gpy_get_wol,
                .set_loopback   = gpy115_loopback,
@@ -258,7 +258,7 @@ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
        },
        {
                .phy_id         = PHY_ID_GPY211B,
-@@ -897,6 +1085,11 @@ static struct phy_driver gpy_drivers[] =
+@@ -905,6 +1093,11 @@ static struct phy_driver gpy_drivers[] =
                .set_wol        = gpy_set_wol,
                .get_wol        = gpy_get_wol,
                .set_loopback   = gpy_loopback,
@@ -270,7 +270,7 @@ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
        },
        {
                PHY_ID_MATCH_MODEL(PHY_ID_GPY211C),
-@@ -914,6 +1107,11 @@ static struct phy_driver gpy_drivers[] =
+@@ -922,6 +1115,11 @@ static struct phy_driver gpy_drivers[] =
                .set_wol        = gpy_set_wol,
                .get_wol        = gpy_get_wol,
                .set_loopback   = gpy_loopback,
@@ -282,7 +282,7 @@ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
        },
        {
                .phy_id         = PHY_ID_GPY212B,
-@@ -932,6 +1130,11 @@ static struct phy_driver gpy_drivers[] =
+@@ -940,6 +1138,11 @@ static struct phy_driver gpy_drivers[] =
                .set_wol        = gpy_set_wol,
                .get_wol        = gpy_get_wol,
                .set_loopback   = gpy_loopback,
@@ -294,7 +294,7 @@ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
        },
        {
                PHY_ID_MATCH_MODEL(PHY_ID_GPY212C),
-@@ -949,6 +1152,11 @@ static struct phy_driver gpy_drivers[] =
+@@ -957,6 +1160,11 @@ static struct phy_driver gpy_drivers[] =
                .set_wol        = gpy_set_wol,
                .get_wol        = gpy_get_wol,
                .set_loopback   = gpy_loopback,
@@ -306,7 +306,7 @@ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
        },
        {
                .phy_id         = PHY_ID_GPY215B,
-@@ -967,6 +1175,11 @@ static struct phy_driver gpy_drivers[] =
+@@ -975,6 +1183,11 @@ static struct phy_driver gpy_drivers[] =
                .set_wol        = gpy_set_wol,
                .get_wol        = gpy_get_wol,
                .set_loopback   = gpy_loopback,
@@ -318,7 +318,7 @@ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
        },
        {
                PHY_ID_MATCH_MODEL(PHY_ID_GPY215C),
-@@ -984,6 +1197,11 @@ static struct phy_driver gpy_drivers[] =
+@@ -992,6 +1205,11 @@ static struct phy_driver gpy_drivers[] =
                .set_wol        = gpy_set_wol,
                .get_wol        = gpy_get_wol,
                .set_loopback   = gpy_loopback,
index 067c62da11ef81ef5014b4787e3a9636afa3ea42..39bef9b9822f67fba37a9e52b87784124e3f0cac 100644 (file)
@@ -18,7 +18,7 @@ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
 
 --- a/drivers/net/phy/mxl-gpy.c
 +++ b/drivers/net/phy/mxl-gpy.c
-@@ -876,6 +876,7 @@ static int gpy_led_brightness_set(struct
+@@ -884,6 +884,7 @@ static int gpy_led_brightness_set(struct
  }
  
  static const unsigned long supported_triggers = (BIT(TRIGGER_NETDEV_LINK) |
index 5b88548dd06a3c1f31c03a9a2fdd9ff665771b89..5fd3dcc77be1256d4bf1fc0d5e070c38db4f2c13 100644 (file)
@@ -20,7 +20,7 @@ Signed-off-by: Paolo Abeni <pabeni@redhat.com>
 
 --- a/drivers/net/phy/mxl-gpy.c
 +++ b/drivers/net/phy/mxl-gpy.c
-@@ -981,7 +981,7 @@ static int gpy_led_hw_control_set(struct
+@@ -989,7 +989,7 @@ static int gpy_led_hw_control_set(struct
  static int gpy_led_polarity_set(struct phy_device *phydev, int index,
                                unsigned long modes)
  {
@@ -29,7 +29,7 @@ Signed-off-by: Paolo Abeni <pabeni@redhat.com>
        u32 mode;
  
        if (index >= GPY_MAX_LEDS)
-@@ -990,15 +990,23 @@ static int gpy_led_polarity_set(struct p
+@@ -998,15 +998,23 @@ static int gpy_led_polarity_set(struct p
        for_each_set_bit(mode, &modes, __PHY_LED_MODES_NUM) {
                switch (mode) {
                case PHY_LED_ACTIVE_LOW:
index 711246da617e095f618691a449663fa71aa7cb7e..84d760a836456b4d3321d5f4c48574b361d6cb14 100644 (file)
@@ -127,7 +127,7 @@ Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
  #include <linux/netdevice.h>
  #include <linux/gpio/consumer.h>
  #include <linux/phylink.h>
-@@ -3235,14 +3236,43 @@ static int mv88e6xxx_setup_upstream_port
+@@ -3371,14 +3372,43 @@ static int mv88e6xxx_setup_upstream_port
  static int mv88e6xxx_setup_port(struct mv88e6xxx_chip *chip, int port)
  {
        struct device_node *phy_handle = NULL;
@@ -173,7 +173,7 @@ Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
  
        err = mv88e6xxx_port_setup_mac(chip, port, LINK_UNFORCED,
                                       SPEED_UNFORCED, DUPLEX_UNFORCED,
-@@ -4461,6 +4491,7 @@ static const struct mv88e6xxx_ops mv88e6
+@@ -4597,6 +4627,7 @@ static const struct mv88e6xxx_ops mv88e6
        .port_disable_learn_limit = mv88e6xxx_port_disable_learn_limit,
        .port_disable_pri_override = mv88e6xxx_port_disable_pri_override,
        .port_get_cmode = mv88e6352_port_get_cmode,
@@ -181,7 +181,7 @@ Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
        .port_setup_message_port = mv88e6xxx_setup_message_port,
        .stats_snapshot = mv88e6320_g1_stats_snapshot,
        .stats_set_histogram = mv88e6095_g1_stats_set_histogram,
-@@ -4563,6 +4594,7 @@ static const struct mv88e6xxx_ops mv88e6
+@@ -4699,6 +4730,7 @@ static const struct mv88e6xxx_ops mv88e6
        .port_disable_learn_limit = mv88e6xxx_port_disable_learn_limit,
        .port_disable_pri_override = mv88e6xxx_port_disable_pri_override,
        .port_get_cmode = mv88e6352_port_get_cmode,
@@ -189,7 +189,7 @@ Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
        .port_setup_message_port = mv88e6xxx_setup_message_port,
        .stats_snapshot = mv88e6320_g1_stats_snapshot,
        .stats_set_histogram = mv88e6095_g1_stats_set_histogram,
-@@ -4838,6 +4870,7 @@ static const struct mv88e6xxx_ops mv88e6
+@@ -4974,6 +5006,7 @@ static const struct mv88e6xxx_ops mv88e6
        .port_disable_learn_limit = mv88e6xxx_port_disable_learn_limit,
        .port_disable_pri_override = mv88e6xxx_port_disable_pri_override,
        .port_get_cmode = mv88e6352_port_get_cmode,
@@ -197,7 +197,7 @@ Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
        .port_setup_message_port = mv88e6xxx_setup_message_port,
        .stats_snapshot = mv88e6320_g1_stats_snapshot,
        .stats_set_histogram = mv88e6095_g1_stats_set_histogram,
-@@ -5260,6 +5293,7 @@ static const struct mv88e6xxx_ops mv88e6
+@@ -5396,6 +5429,7 @@ static const struct mv88e6xxx_ops mv88e6
        .port_disable_learn_limit = mv88e6xxx_port_disable_learn_limit,
        .port_disable_pri_override = mv88e6xxx_port_disable_pri_override,
        .port_get_cmode = mv88e6352_port_get_cmode,
@@ -237,7 +237,7 @@ Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
        /* MacAuth Bypass control flag */
        bool mab;
  };
-@@ -563,6 +571,9 @@ struct mv88e6xxx_ops {
+@@ -574,6 +582,9 @@ struct mv88e6xxx_ops {
                              phy_interface_t mode);
        int (*port_get_cmode)(struct mv88e6xxx_chip *chip, int port, u8 *cmode);
  
@@ -973,8 +973,8 @@ Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
 +      dp = dsa_to_port(p->chip->ds, p->port);
 +      if (!dp)
 +              return NULL;
-+      if (dp->slave)
-+              return &dp->slave->dev;
++      if (dp->user)
++              return &dp->user->dev;
 +      return NULL;
 +}
 +