On 7/19/22 04:15, Avri Altman wrote:
@@ -9601,6 +9602,7 @@ int ufshcd_alloc_host(struct device *dev, struct
ufs_hba **hba_handle)
hba->dev = dev;
hba->dev_ref_clk_freq = REF_CLK_FREQ_INVAL;
hba->nop_out_timeout = NOP_OUT_TIMEOUT;
+ ufshcd_set_sg_entry_size(hba, sizeof(struct ufshcd_sg_entry));
Where are you setting this variant for ufs-exynos?
I would expect here a set_sg_entry_size vop.
The Exynos code used in Pixel 6 phones is available for download from a
Google server but is not yet upstream unfortunately. This is why no
ufshcd_set_sg_entry_size() call has been added in the ufs-exynos driver.
+#define ufshcd_set_sg_entry_size(hba, sg_entry_size) \
+ ({ (void)(hba); BUILD_BUG_ON(sg_entry_size != sizeof(struct
ufshcd_sg_entry)); })
Why not static inline void?
Because sg_entry_size is used inside BUILD_BUG_ON(). The resulting code
does not compile if the above macro is changed into a function.
Thanks,
Bart.