On 3/5/20 6:12 PM, Dmitry Osipenko wrote: > All NVIDIA Tegra devices use a special partition table format for the > internal storage partitioning. Most of Tegra devices have GPT partition > in addition to TegraPT, but some older Android consumer-grade devices do > not or GPT is placed in a wrong sector, and thus, the TegraPT is needed > in order to support these devices properly in the upstream kernel. This > patch adds support for NVIDIA Tegra Partition Table format that is used > at least by all NVIDIA Tegra20 and Tegra30 devices. > > Signed-off-by: Dmitry Osipenko <digetx@xxxxxxxxx> > --- > arch/arm/mach-tegra/tegra.c | 54 ++++ > block/partitions/Kconfig | 9 + > block/partitions/Makefile | 1 + > block/partitions/check.c | 4 + > block/partitions/tegra.c | 510 ++++++++++++++++++++++++++++++++++ > block/partitions/tegra.h | 83 ++++++ > include/soc/tegra/bootdata.h | 46 +++ > include/soc/tegra/common.h | 9 + > include/soc/tegra/partition.h | 18 ++ > 9 files changed, 734 insertions(+) > create mode 100644 block/partitions/tegra.c > create mode 100644 block/partitions/tegra.h > create mode 100644 include/soc/tegra/bootdata.h > create mode 100644 include/soc/tegra/partition.h Hi Dmitry, > diff --git a/block/partitions/Kconfig b/block/partitions/Kconfig > index 702689a628f0..d3c5c6ad6d58 100644 > --- a/block/partitions/Kconfig > +++ b/block/partitions/Kconfig > @@ -268,3 +268,12 @@ config CMDLINE_PARTITION > help > Say Y here if you want to read the partition table from bootargs. > The format for the command line is just like mtdparts. > + > +config TEGRA_PARTITION > + bool "NVIDIA Tegra Partition support" if PARTITION_ADVANCED > + default y if ARCH_TEGRA > + depends on ARCH_TEGRA || COMPILE_TEST > + select MMC_BLOCK You shouldn't select MMC_BLOCK unless MMC is already enabled, so this entire config should depend on MMC also. As is, without MMC set/enabled, it should give you a kconfig warning. (no, you should not also select MMC here.) (This is just based on reading the patch--I haven't tested it with CONFIG_MMC not set/enabled. Have you?) > + help > + Say Y here if you would like to be able to read the hard disk > + partition table format used by NVIDIA Tegra machines. Thanks. -- ~Randy