Re: [PATCH v3 07/11] net: ethernet: stmmac: add management of stm32mp13 for stm32

From: Marek Vasut
Date: Mon Jun 03 2024 - 10:30:25 EST


On 6/3/24 1:30 PM, Rasmus Villemoes wrote:
On 03/06/2024 11.27, Christophe Roullier wrote:

@@ -259,13 +268,17 @@ static int stm32mp1_configure_pmcr(struct plat_stmmacenet_data *plat_dat)
dev_dbg(dwmac->dev, "Mode %s", phy_modes(plat_dat->mac_interface));
+ /* Shift value at correct ethernet MAC offset in SYSCFG_PMCSETR */
+ val <<= ffs(dwmac->mode_mask) - ffs(SYSCFG_MP1_ETH_MASK);
+
/* Need to update PMCCLRR (clear register) */
- regmap_write(dwmac->regmap, reg + SYSCFG_PMCCLRR_OFFSET,
- dwmac->ops->syscfg_eth_mask);
+ regmap_write(dwmac->regmap, dwmac->ops->syscfg_clr_off,
+ dwmac->mode_mask);
/* Update PMCSETR (set register) */
return regmap_update_bits(dwmac->regmap, reg,
- dwmac->ops->syscfg_eth_mask, val);
+ dwmac->mode_mask, val);
}
static int stm32mp1_set_mode(struct plat_stmmacenet_data *plat_dat)

This hunk is broken, and makes the patch not apply:

Applying: net: ethernet: stmmac: add management of stm32mp13 for stm32
error: corrupt patch at line 70

The -259,13 seems correct, and the net lines added by previous hunks is
indeed +9, but this hunk only adds three more lines than it removes, not
four, so the +268,17 should have been +268,16.

Have you manually edited this patch before sending? If so, please don't
do that, it makes people waste a lot of time figuring out what is wrong.

Also, please include a base-id in the cover letter so one knows what it
applies to.

Just out of curiosity, I know one can generate cover letter from branch description with git branch --edit-description and git format-patch --cover-from-description= , but is there something to automatically fill in the merge base (I assume that's what you want) ?

Or are you looking for git send-email --subject-prefix="net-next,PATCH" to fill in the net/net-next subject prefix ?