Loading Documentation/devicetree/bindings/mtd/msm_qpic_nand.txt +4 −0 Original line number Diff line number Diff line Loading @@ -7,6 +7,8 @@ Required properties: - interrupts : should specify QPIC/BAM interrupt numbers. - interrupt-names : should specify relevant names to each interrupts property defined. - qcom,reg-adjustment-offset : Specify the base adjustment offset value for the version registers MTD flash partition layout for NAND devices - Loading Loading @@ -37,6 +39,8 @@ Examples: <0xf9ac4000 0x8000>; reg-names = "nand_phys", "bam_phys"; qcom,reg-adjustment-offset = <0x4000>; interrupts = <0 279 0>; interrupt-names = "bam_irq"; Loading arch/arm/boot/dts/qcom/mdm9607.dtsi +2 −0 Original line number Diff line number Diff line Loading @@ -646,6 +646,8 @@ <0x07984000 0x1a000>; reg-names = "nand_phys", "bam_phys"; qcom,reg-adjustment-offset = <0x4000>; interrupts = <0 132 0>; interrupt-names = "bam_irq"; Loading arch/arm/boot/dts/qcom/mdm9640.dtsi +2 −0 Original line number Diff line number Diff line Loading @@ -595,6 +595,8 @@ <0x07984000 0x1a000>; reg-names = "nand_phys", "bam_phys"; qcom,reg-adjustment-offset = <0>; interrupts = <0 247 0>; interrupt-names = "bam_irq"; Loading arch/arm/boot/dts/qcom/mdmcalifornium.dtsi +2 −0 Original line number Diff line number Diff line Loading @@ -632,6 +632,8 @@ <0x07984000 0x1a000>; reg-names = "nand_phys", "bam_phys"; qcom,reg-adjustment-offset = <0x4000>; interrupts = <0 247 0>; interrupt-names = "bam_irq"; Loading drivers/mtd/devices/msm_qpic_nand.c +14 −1 Original line number Diff line number Diff line /* * Copyright (C) 2007 Google, Inc. * Copyright (c) 2012-2015, The Linux Foundation. All rights reserved. * Copyright (c) 2012-2016, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -3363,6 +3363,7 @@ static int msm_nand_probe(struct platform_device *pdev) struct resource *res; int i, err, nr_parts; struct device *dev; u32 adjustment_offset; /* * The partition information can also be passed from kernel command * line. Also, the MTD core layer supports adding the whole device as Loading @@ -3382,6 +3383,18 @@ static int msm_nand_probe(struct platform_device *pdev) goto out; } info->nand_phys = res->start; err = of_property_read_u32(pdev->dev.of_node, "qcom,reg-adjustment-offset", &adjustment_offset); if (err) { pr_err("adjustment_offset not found, err = %d\n", err); WARN_ON(1); return err; } info->nand_phys_adjusted = info->nand_phys + adjustment_offset; res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "bam_phys"); if (!res || !res->start) { Loading Loading
Documentation/devicetree/bindings/mtd/msm_qpic_nand.txt +4 −0 Original line number Diff line number Diff line Loading @@ -7,6 +7,8 @@ Required properties: - interrupts : should specify QPIC/BAM interrupt numbers. - interrupt-names : should specify relevant names to each interrupts property defined. - qcom,reg-adjustment-offset : Specify the base adjustment offset value for the version registers MTD flash partition layout for NAND devices - Loading Loading @@ -37,6 +39,8 @@ Examples: <0xf9ac4000 0x8000>; reg-names = "nand_phys", "bam_phys"; qcom,reg-adjustment-offset = <0x4000>; interrupts = <0 279 0>; interrupt-names = "bam_irq"; Loading
arch/arm/boot/dts/qcom/mdm9607.dtsi +2 −0 Original line number Diff line number Diff line Loading @@ -646,6 +646,8 @@ <0x07984000 0x1a000>; reg-names = "nand_phys", "bam_phys"; qcom,reg-adjustment-offset = <0x4000>; interrupts = <0 132 0>; interrupt-names = "bam_irq"; Loading
arch/arm/boot/dts/qcom/mdm9640.dtsi +2 −0 Original line number Diff line number Diff line Loading @@ -595,6 +595,8 @@ <0x07984000 0x1a000>; reg-names = "nand_phys", "bam_phys"; qcom,reg-adjustment-offset = <0>; interrupts = <0 247 0>; interrupt-names = "bam_irq"; Loading
arch/arm/boot/dts/qcom/mdmcalifornium.dtsi +2 −0 Original line number Diff line number Diff line Loading @@ -632,6 +632,8 @@ <0x07984000 0x1a000>; reg-names = "nand_phys", "bam_phys"; qcom,reg-adjustment-offset = <0x4000>; interrupts = <0 247 0>; interrupt-names = "bam_irq"; Loading
drivers/mtd/devices/msm_qpic_nand.c +14 −1 Original line number Diff line number Diff line /* * Copyright (C) 2007 Google, Inc. * Copyright (c) 2012-2015, The Linux Foundation. All rights reserved. * Copyright (c) 2012-2016, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -3363,6 +3363,7 @@ static int msm_nand_probe(struct platform_device *pdev) struct resource *res; int i, err, nr_parts; struct device *dev; u32 adjustment_offset; /* * The partition information can also be passed from kernel command * line. Also, the MTD core layer supports adding the whole device as Loading @@ -3382,6 +3383,18 @@ static int msm_nand_probe(struct platform_device *pdev) goto out; } info->nand_phys = res->start; err = of_property_read_u32(pdev->dev.of_node, "qcom,reg-adjustment-offset", &adjustment_offset); if (err) { pr_err("adjustment_offset not found, err = %d\n", err); WARN_ON(1); return err; } info->nand_phys_adjusted = info->nand_phys + adjustment_offset; res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "bam_phys"); if (!res || !res->start) { Loading