diff options
author | Tom Rini | 2023-02-17 14:18:46 -0500 |
---|---|---|
committer | Tom Rini | 2023-02-17 14:18:46 -0500 |
commit | 1198b38ba980efed050c878c083607d997010e03 (patch) | |
tree | 94338bc92230241c8415fe69fcd33ea3dcb40dcb | |
parent | fcb5117da8876fc5b2bf941528301218d1be7b1c (diff) | |
parent | 3106e475243e1e35df18d5086f7a5df8758bbda1 (diff) |
Merge branch '2023-02-17-assorted-fixes'
- avb_verify bugfix, and cpsw_mdio bugfix
-rw-r--r-- | common/avb_verify.c | 9 | ||||
-rw-r--r-- | drivers/net/ti/cpsw_mdio.c | 6 |
2 files changed, 8 insertions, 7 deletions
diff --git a/common/avb_verify.c b/common/avb_verify.c index 0520a714556..48ba8db51e5 100644 --- a/common/avb_verify.c +++ b/common/avb_verify.c @@ -619,10 +619,11 @@ static int get_open_session(struct AvbOpsData *ops_data) memset(&arg, 0, sizeof(arg)); tee_optee_ta_uuid_to_octets(arg.uuid, &uuid); rc = tee_open_session(tee, &arg, 0, NULL); - if (!rc) { - ops_data->tee = tee; - ops_data->session = arg.session; - } + if (rc || arg.ret) + continue; + + ops_data->tee = tee; + ops_data->session = arg.session; } return 0; diff --git a/drivers/net/ti/cpsw_mdio.c b/drivers/net/ti/cpsw_mdio.c index a5ba73b7398..ac791faa813 100644 --- a/drivers/net/ti/cpsw_mdio.c +++ b/drivers/net/ti/cpsw_mdio.c @@ -51,7 +51,7 @@ struct cpsw_mdio_regs { #define USERACCESS_PHY_REG_SHIFT (21) #define USERACCESS_PHY_ADDR_SHIFT (16) #define USERACCESS_DATA GENMASK(15, 0) - } user[0]; + } user[2]; }; #define CPSW_MDIO_DIV_DEF 0xff @@ -366,8 +366,8 @@ u32 cpsw_mdio_get_alive(struct mii_dev *bus) struct cpsw_mdio *mdio = bus->priv; u32 val; - val = readl(&mdio->regs->control); - return val & GENMASK(15, 0); + val = readl(&mdio->regs->alive); + return val & GENMASK(7, 0); } struct mii_dev *cpsw_mdio_init(const char *name, phys_addr_t mdio_base, |