MLK-14388 mtd: gpmi: remove direct mtd->priv accesses
mtd->priv is no longer pointing to the struct nand_chip it is attached to. Replace those accesses by mtd_to_nand() calls. Signed-off-by: Octavian Purdila <octavian.purdila@nxp.com>
This commit is contained in:
committed by
Leonard Crestez
parent
0a0563589f
commit
8b7f45b095
@ -343,7 +343,7 @@ static int set_geometry_for_large_oob(struct gpmi_nand_data *this)
|
||||
{
|
||||
struct bch_geometry *geo = &this->bch_geometry;
|
||||
struct mtd_info *mtd = &this->nand.mtd;
|
||||
struct nand_chip *chip = mtd->priv;
|
||||
struct nand_chip *chip = mtd_to_nand(mtd);
|
||||
unsigned int block_mark_bit_offset;
|
||||
unsigned int max_ecc;
|
||||
unsigned int bbm_chunk;
|
||||
@ -581,7 +581,7 @@ static int legacy_set_geometry(struct gpmi_nand_data *this)
|
||||
int common_nfc_set_geometry(struct gpmi_nand_data *this)
|
||||
{
|
||||
struct mtd_info *mtd = &this->nand.mtd;
|
||||
struct nand_chip *chip = mtd->priv;
|
||||
struct nand_chip *chip = mtd_to_nand(mtd);
|
||||
|
||||
if (chip->ecc_strength_ds > this->devdata->bch_max_ecc_strength) {
|
||||
dev_err(this->dev,
|
||||
|
||||
Reference in New Issue
Block a user