- 30 Mar, 2021 3 commits
-
-
Stephane Fillod authored
These warnings were mainly found using cppcheck. Signed-off-by: Stephane Fillod <f8cfe@free.fr> Reviewed-by: Michael Heimpold <mhei@heimpold.de> Link: https://lore.kernel.org/r/1254580747.16828401.1547561163645.JavaMail.root@zimbra64-e11.priv.proxad.net Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
-
Stephane Fillod authored
Part if this list update comes from a compilation of this web site[1]. [1] https://www.cameramemoryspeed.com/sd-memory-card-faq/reading-sd-card-cid-serial-psn-internal-numbers/ Signed-off-by: Stephane Fillod <f8cfe@free.fr> Link: https://lore.kernel.org/r/886907785.16708970.1547560575203.JavaMail.root@zimbra64-e11.priv.proxad.net Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
-
Stephane Fillod authored
According to MMC Standard (similar to SDCard Standard). Signed-off-by: Stephane Fillod <f8cfe@free.fr> Acked-by: Avri Altman <avri.altman@wdc.com> Link: https://lore.kernel.org/r/1823652044.3512532.1547484650178.JavaMail.root@zimbra64-e11.priv.proxad.net Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
-
- 05 Oct, 2019 5 commits
-
-
Michael Heimpold authored
Signed-off-by: Michael Heimpold <michael.heimpold@i2se.com> Cc: Michael Heimpold <mhei@heimpold.de> Reviewed-by: Avri Altman <avri.altman@wdc.com> Signed-off-by: Chris Ball <chris@printf.net>
-
Michael Heimpold authored
Appending multiple times to same string is slow since strcat() needs to determine the end during each run. So manually maintain a pointer to the end to speed-up things. Signed-off-by: Michael Heimpold <michael.heimpold@i2se.com> Cc: Michael Heimpold <mhei@heimpold.de> Reviewed-by: Avri Altman <avri.altman@wdc.com> Signed-off-by: Chris Ball <chris@printf.net>
-
Michael Heimpold authored
When a hex-digit > 'a' or 'A' is read, we have to add an offset of 10 to access the valid symbol in our mapping table. Signed-off-by: Michael Heimpold <michael.heimpold@i2se.com> Cc: Michael Heimpold <mhei@heimpold.de> Reviewed-by: Avri Altman <avri.altman@wdc.com> Signed-off-by: Chris Ball <chris@printf.net>
-
Michael Heimpold authored
In case that we leave due to malformed string, free the allocated memory before returning. Signed-off-by: Michael Heimpold <michael.heimpold@i2se.com> Cc: Michael Heimpold <mhei@heimpold.de> Reviewed-by: Avri Altman <avri.altman@wdc.com> Signed-off-by: Chris Ball <chris@printf.net>
-
Michael Heimpold authored
If calloc fails, bail out immediately instead of trying to use the NULL pointer. Signed-off-by: Michael Heimpold <michael.heimpold@i2se.com> Cc: Michael Heimpold <mhei@heimpold.de> Reviewed-by: Avri Altman <avri.altman@wdc.com> Signed-off-by: Chris Ball <chris@printf.net>
-
- 08 Dec, 2018 1 commit
-
-
Wolfram Sang authored
I got a compile error with GCC7. When trimming white spaces from strings lsmmc uses strncpy with overlapping memory areas. This is not allowed. In addition, the implementation was not efficient with calling strlen and strncpy once per iteration. Refactor the code to be valid and more effective. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Chris Ball <chris@printf.net>
-
- 17 Feb, 2018 1 commit
-
-
Uwe Kleine-König authored
This macro saves a few lines of code but is harder to read than the equivalent code spelled out. IMHO the latter is more important, so expand the macro everywhere and drop it. While touching this also unbreak the strings used there for better grepability. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Chris Ball <chris@printf.net>
-
- 26 Feb, 2016 1 commit
-
-
Sebastian Rasmussen authored
The lsmmc tools contains an extensive parser of the CID, CSD, SCR registers from userspace. The utility works as-is and uses sysfs to read the register values. The original code is created by Sebastian Rasmussen and still lives in an attachment in the mail archive of linux-mmc. It need to be merged into mmc-utils repository, which is convenient for testing MMC device from userspace. Change since v3: - Remove the unused EXT_CSD parser in lsmmc.c file. Signed-off-by: Sebastian Rasmussen <sebras@gmail.com> Signed-off-by: Chris Ball <chris@printf.net> Signed-off-by: Baolin Wang <baolin.wang@linaro.org>
-