* Re: next/master bisection: baseline.login on mt8173-elm-hana [not found] <6391e1c4.170a0220.b562d.3c9c@mx.google.com> @ 2022-12-08 13:48 ` Mark Brown 0 siblings, 0 replies; 8+ messages in thread From: Mark Brown @ 2022-12-08 13:48 UTC (permalink / raw) To: Joerg Roedel, Matthias Brugger, Will Deacon, Yong Wu, kernelci-results, bot Cc: gtucker, iommu, linux-mediatek, linux-arm-kernel, angelogioacchino.delregno, mingyuan.ma, libo.kang, chengci.xu, yf.wang, youlin.pei, anan.sun, xueqi.zhang, Guenter Roeck [-- Attachment #1: Type: text/plain, Size: 11504 bytes --] On Thu, Dec 08, 2022 at 05:08:20AM -0800, KernelCI bot wrote: The KernelCI bisection bot found a boot failure in today's -next on mt8173-elm-hana was triggered by 26593928564cf ("iommu/mediatek: Add error path for loop of mm_dts_parse"). We get an oops towards the end of boot: <6>[ 0.840037] printk: bootconsole [mtk8250] disabled <6>[ 0.840037] printk: bootconsole [mtk8250] disabled <1>[ 0.854924] Unable to handle kernel read from unreadable memory at virtual address 000000000000003b <1>[ 0.864288] Mem abort info: <1>[ 0.867374] ESR = 0x0000000096000005 <1>[ 0.871408] EC = 0x25: DABT (current EL), IL = 32 bits <1>[ 0.877005] SET = 0, FnV = 0 <1>[ 0.880350] EA = 0, S1PTW = 0 <1>[ 0.883776] FSC = 0x05: level 1 translation fault <1>[ 0.888938] Data abort info: ... <4>[ 1.027320] kobject_put+0x18/0xf0 <4>[ 1.030996] put_device+0x1c/0x28 <4>[ 1.034586] mtk_iommu_mm_dts_parse+0x2d0/0x31c <4>[ 1.039394] mtk_iommu_probe+0x2dc/0x4c0 <4>[ 1.043592] platform_probe+0xb0/0xd0 <4>[ 1.047530] really_probe+0xf8/0x280 <4>[ 1.051377] __driver_probe_device+0xbc/0xe8 <4>[ 1.055923] driver_probe_device+0x44/0x104 <4>[ 1.060380] __driver_attach+0xb4/0x108 <4>[ 1.064487] bus_for_each_dev+0x88/0xd4 <4>[ 1.068598] driver_attach+0x2c/0x38 <4>[ 1.072445] bus_add_driver+0x114/0x1f4 <4>[ 1.076554] driver_register+0x6c/0x108 <4>[ 1.080663] __platform_driver_register+0x2c/0x38 <4>[ 1.085640] mtk_iommu_driver_init+0x24/0x30 I've left the full report from the bot below, including links to more detailed information and a Reported-by tag for the bot below, the log links got mangled and should be: https://storage.kernelci.org/next/master/next-20221208/arm64/cros---chromeos-5.10-arm64-chromiumos-mediatek.flavour.config%2Barm64-chromebook/clang-13/lab-collabora/baseline-mt8173-elm-hana.html https://storage.kernelci.org/next/master/next-20221208/arm64/cros---chromeos-5.10-arm64-chromiumos-mediatek.flavour.config%2Barm64-chromebook/clang-13/lab-collabora/baseline-mt8173-elm-hana.txt > * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * > * This automated bisection report was sent to you on the basis * > * that you may be involved with the breaking commit it has * > * found. No manual investigation has been done to verify it, * > * and the root cause of the problem may be somewhere else. * > * * > * If you do send a fix, please include this trailer: * > * Reported-by: "kernelci.org bot" <bot@kernelci.org> * > * * > * Hope this helps! * > * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * > > next/master bisection: baseline.login on mt8173-elm-hana > > Summary: > Start: f925116b24c0c Add linux-next specific files for 20221208 > Plain log: https://storage.kernelci.org/next/master/next-20221208/arm64/cros://chromeos-5.10/arm64/chromiumos-arm64.flavour.config+arm64-chromebook/clang-13/lab-collabora/baseline-mt8173-elm-hana.txt > HTML log: https://storage.kernelci.org/next/master/next-20221208/arm64/cros://chromeos-5.10/arm64/chromiumos-arm64.flavour.config+arm64-chromebook/clang-13/lab-collabora/baseline-mt8173-elm-hana.html > Result: 26593928564cf iommu/mediatek: Add error path for loop of mm_dts_parse > > Checks: > revert: PASS > verify: PASS > > Parameters: > Tree: next > URL: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git > Branch: master > Target: mt8173-elm-hana > CPU arch: arm64 > Lab: lab-collabora > Compiler: clang-13 > Config: cros://chromeos-5.10/arm64/chromiumos-arm64.flavour.config+arm64-chromebook > Test case: baseline.login > > Breaking commit found: > > ------------------------------------------------------------------------------- > commit 26593928564cf5b576ff05d3cbd958f57c9534bb > Author: Yong Wu <yong.wu@mediatek.com> > Date: Tue Oct 18 10:42:55 2022 +0800 > > iommu/mediatek: Add error path for loop of mm_dts_parse > > The mtk_iommu_mm_dts_parse will parse the smi larbs nodes. if the i+1 > larb is parsed fail, we should put_device for the i..0 larbs. > > There are two places need to comment: > 1) The larbid may be not linear mapping, we should loop whole > the array in the error path. > 2) I move this line position: "data->larb_imu[id].dev = &plarbdev->dev;" > before "if (!plarbdev->dev.driver)", That means set > data->larb_imu[id].dev before the error path. then we don't need > "platform_device_put(plarbdev)" again in probe_defer case. All depend > on "put_device" of the error path in error cases. > > Fixes: d2e9a1102cfc ("iommu/mediatek: Contain MM IOMMU flow with the MM TYPE") > Signed-off-by: Yong Wu <yong.wu@mediatek.com> > Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> > Reviewed-by: Matthias Brugger <matthias.bgg@gmail.com> > Link: https://lore.kernel.org/r/20221018024258.19073-4-yong.wu@mediatek.com > Signed-off-by: Joerg Roedel <jroedel@suse.de> > > diff --git a/drivers/iommu/mtk_iommu.c b/drivers/iommu/mtk_iommu.c > index df490236e1fb5..e0c669b75271d 100644 > --- a/drivers/iommu/mtk_iommu.c > +++ b/drivers/iommu/mtk_iommu.c > @@ -1067,8 +1067,10 @@ static int mtk_iommu_mm_dts_parse(struct device *dev, struct component_match **m > u32 id; > > larbnode = of_parse_phandle(dev->of_node, "mediatek,larbs", i); > - if (!larbnode) > - return -EINVAL; > + if (!larbnode) { > + ret = -EINVAL; > + goto err_larbdev_put; > + } > > if (!of_device_is_available(larbnode)) { > of_node_put(larbnode); > @@ -1081,14 +1083,16 @@ static int mtk_iommu_mm_dts_parse(struct device *dev, struct component_match **m > > plarbdev = of_find_device_by_node(larbnode); > of_node_put(larbnode); > - if (!plarbdev) > - return -ENODEV; > + if (!plarbdev) { > + ret = -ENODEV; > + goto err_larbdev_put; > + } > + data->larb_imu[id].dev = &plarbdev->dev; > > if (!plarbdev->dev.driver) { > - platform_device_put(plarbdev); > - return -EPROBE_DEFER; > + ret = -EPROBE_DEFER; > + goto err_larbdev_put; > } > - data->larb_imu[id].dev = &plarbdev->dev; > > component_match_add(dev, match, component_compare_dev, &plarbdev->dev); > platform_device_put(plarbdev); > @@ -1123,6 +1127,15 @@ static int mtk_iommu_mm_dts_parse(struct device *dev, struct component_match **m > return -EINVAL; > } > return 0; > + > +err_larbdev_put: > + /* id may be not linear mapping, loop whole the array */ > + for (i = MTK_LARB_NR_MAX - 1; i >= 0; i++) { > + if (!data->larb_imu[i].dev) > + continue; > + put_device(data->larb_imu[i].dev); > + } > + return ret; > } > > static int mtk_iommu_probe(struct platform_device *pdev) > ------------------------------------------------------------------------------- > > > Git bisection log: > > ------------------------------------------------------------------------------- > git bisect start > # good: [479174d402bcf60789106eedc4def3957c060bad] Merge tag 'platform-drivers-x86-v6.1-5' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86 > git bisect good 479174d402bcf60789106eedc4def3957c060bad > # bad: [f925116b24c0c42dc6d5ab5111c55fd7f74e8dc7] Add linux-next specific files for 20221208 > git bisect bad f925116b24c0c42dc6d5ab5111c55fd7f74e8dc7 > # good: [a1c975859da787104f6f2610f0f5507ef794dea4] Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git > git bisect good a1c975859da787104f6f2610f0f5507ef794dea4 > # bad: [df52ed561d70653b4d82a468026450374161693b] Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git > git bisect bad df52ed561d70653b4d82a468026450374161693b > # good: [ddf1b69a1f2e0704bc0d5f7f71e4f8c4891a3bbb] Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git > git bisect good ddf1b69a1f2e0704bc0d5f7f71e4f8c4891a3bbb > # good: [b5cb3c9818c0085928c1d795e1e2a78add3dbca5] Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git > git bisect good b5cb3c9818c0085928c1d795e1e2a78add3dbca5 > # bad: [b07fcd1e4269638ae72abc499543eb72605bd34b] Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git > git bisect bad b07fcd1e4269638ae72abc499543eb72605bd34b > # bad: [147cf2079e0afce372e3d14089396736a025ecda] Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/pcmoore/audit.git > git bisect bad 147cf2079e0afce372e3d14089396736a025ecda > # good: [14d40e4c74b85c390e076712a6d2831e9464b786] Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/jarkko/linux-tpmdd.git > git bisect good 14d40e4c74b85c390e076712a6d2831e9464b786 > # good: [b169a180bef26679b44484ad24b7d8ae32623a10] iommu/io-pgtable: Remove map/unmap > git bisect good b169a180bef26679b44484ad24b7d8ae32623a10 > # good: [f04ae51dd965bc0b7f2e01c5d85fc214877b4061] Merge tag 'arm-smmu-updates' of git://git.kernel.org/pub/scm/linux/kernel/git/will/linux into arm/smmu > git bisect good f04ae51dd965bc0b7f2e01c5d85fc214877b4061 > # bad: [4dd549a66a969ccd3ed344f37fb9b9e9516fc1e6] Merge branches 'iommu/fixes', 'arm/allwinner', 'arm/exynos', 'arm/mediatek', 'arm/rockchip', 'arm/smmu', 'ppc/pamu', 's390', 'x86/vt-d', 'x86/amd' and 'core' into next > git bisect bad 4dd549a66a969ccd3ed344f37fb9b9e9516fc1e6 > # good: [21c1f9021f0e7d28c3edfcc70e1ca1926ea3774e] s390/pci: use lock-free I/O translation updates > git bisect good 21c1f9021f0e7d28c3edfcc70e1ca1926ea3774e > # bad: [00ef8885a945c37551547d8ac8361cacd20c4e42] iommu/mediatek: Fix crash on isr after kexec() > git bisect bad 00ef8885a945c37551547d8ac8361cacd20c4e42 > # good: [dcb40e9fcce9bd251eaff19f3724131db522846c] iommu/mediatek: Add platform_device_put for recovering the device refcnt > git bisect good dcb40e9fcce9bd251eaff19f3724131db522846c > # bad: [ef693a8440926884bfd9cc3d6d36f65719513350] iommu/mediatek: Validate number of phandles associated with "mediatek,larbs" > git bisect bad ef693a8440926884bfd9cc3d6d36f65719513350 > # bad: [26593928564cf5b576ff05d3cbd958f57c9534bb] iommu/mediatek: Add error path for loop of mm_dts_parse > git bisect bad 26593928564cf5b576ff05d3cbd958f57c9534bb > # good: [b5765a1b44bea9dfcae69c53ffeb4c689d0922a7] iommu/mediatek: Use component_match_add > git bisect good b5765a1b44bea9dfcae69c53ffeb4c689d0922a7 > # first bad commit: [26593928564cf5b576ff05d3cbd958f57c9534bb] iommu/mediatek: Add error path for loop of mm_dts_parse > ------------------------------------------------------------------------------- > > > -=-=-=-=-=-=-=-=-=-=-=- > Groups.io Links: You receive all messages sent to this group. > View/Reply Online (#35262): https://groups.io/g/kernelci-results/message/35262 > Mute This Topic: https://groups.io/mt/95537191/1131744 > Group Owner: kernelci-results+owner@groups.io > Unsubscribe: https://groups.io/g/kernelci-results/unsub [broonie@kernel.org] > -=-=-=-=-=-=-=-=-=-=-=- > > [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 488 bytes --] ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: next/master bisection: baseline.login on mt8173-elm-hana @ 2022-12-08 13:48 ` Mark Brown 0 siblings, 0 replies; 8+ messages in thread From: Mark Brown @ 2022-12-08 13:48 UTC (permalink / raw) To: Joerg Roedel, Matthias Brugger, Will Deacon, Yong Wu, kernelci-results, bot Cc: gtucker, iommu, linux-mediatek, linux-arm-kernel, angelogioacchino.delregno, mingyuan.ma, libo.kang, chengci.xu, yf.wang, youlin.pei, anan.sun, xueqi.zhang, Guenter Roeck [-- Attachment #1.1: Type: text/plain, Size: 11504 bytes --] On Thu, Dec 08, 2022 at 05:08:20AM -0800, KernelCI bot wrote: The KernelCI bisection bot found a boot failure in today's -next on mt8173-elm-hana was triggered by 26593928564cf ("iommu/mediatek: Add error path for loop of mm_dts_parse"). We get an oops towards the end of boot: <6>[ 0.840037] printk: bootconsole [mtk8250] disabled <6>[ 0.840037] printk: bootconsole [mtk8250] disabled <1>[ 0.854924] Unable to handle kernel read from unreadable memory at virtual address 000000000000003b <1>[ 0.864288] Mem abort info: <1>[ 0.867374] ESR = 0x0000000096000005 <1>[ 0.871408] EC = 0x25: DABT (current EL), IL = 32 bits <1>[ 0.877005] SET = 0, FnV = 0 <1>[ 0.880350] EA = 0, S1PTW = 0 <1>[ 0.883776] FSC = 0x05: level 1 translation fault <1>[ 0.888938] Data abort info: ... <4>[ 1.027320] kobject_put+0x18/0xf0 <4>[ 1.030996] put_device+0x1c/0x28 <4>[ 1.034586] mtk_iommu_mm_dts_parse+0x2d0/0x31c <4>[ 1.039394] mtk_iommu_probe+0x2dc/0x4c0 <4>[ 1.043592] platform_probe+0xb0/0xd0 <4>[ 1.047530] really_probe+0xf8/0x280 <4>[ 1.051377] __driver_probe_device+0xbc/0xe8 <4>[ 1.055923] driver_probe_device+0x44/0x104 <4>[ 1.060380] __driver_attach+0xb4/0x108 <4>[ 1.064487] bus_for_each_dev+0x88/0xd4 <4>[ 1.068598] driver_attach+0x2c/0x38 <4>[ 1.072445] bus_add_driver+0x114/0x1f4 <4>[ 1.076554] driver_register+0x6c/0x108 <4>[ 1.080663] __platform_driver_register+0x2c/0x38 <4>[ 1.085640] mtk_iommu_driver_init+0x24/0x30 I've left the full report from the bot below, including links to more detailed information and a Reported-by tag for the bot below, the log links got mangled and should be: https://storage.kernelci.org/next/master/next-20221208/arm64/cros---chromeos-5.10-arm64-chromiumos-mediatek.flavour.config%2Barm64-chromebook/clang-13/lab-collabora/baseline-mt8173-elm-hana.html https://storage.kernelci.org/next/master/next-20221208/arm64/cros---chromeos-5.10-arm64-chromiumos-mediatek.flavour.config%2Barm64-chromebook/clang-13/lab-collabora/baseline-mt8173-elm-hana.txt > * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * > * This automated bisection report was sent to you on the basis * > * that you may be involved with the breaking commit it has * > * found. No manual investigation has been done to verify it, * > * and the root cause of the problem may be somewhere else. * > * * > * If you do send a fix, please include this trailer: * > * Reported-by: "kernelci.org bot" <bot@kernelci.org> * > * * > * Hope this helps! * > * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * > > next/master bisection: baseline.login on mt8173-elm-hana > > Summary: > Start: f925116b24c0c Add linux-next specific files for 20221208 > Plain log: https://storage.kernelci.org/next/master/next-20221208/arm64/cros://chromeos-5.10/arm64/chromiumos-arm64.flavour.config+arm64-chromebook/clang-13/lab-collabora/baseline-mt8173-elm-hana.txt > HTML log: https://storage.kernelci.org/next/master/next-20221208/arm64/cros://chromeos-5.10/arm64/chromiumos-arm64.flavour.config+arm64-chromebook/clang-13/lab-collabora/baseline-mt8173-elm-hana.html > Result: 26593928564cf iommu/mediatek: Add error path for loop of mm_dts_parse > > Checks: > revert: PASS > verify: PASS > > Parameters: > Tree: next > URL: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git > Branch: master > Target: mt8173-elm-hana > CPU arch: arm64 > Lab: lab-collabora > Compiler: clang-13 > Config: cros://chromeos-5.10/arm64/chromiumos-arm64.flavour.config+arm64-chromebook > Test case: baseline.login > > Breaking commit found: > > ------------------------------------------------------------------------------- > commit 26593928564cf5b576ff05d3cbd958f57c9534bb > Author: Yong Wu <yong.wu@mediatek.com> > Date: Tue Oct 18 10:42:55 2022 +0800 > > iommu/mediatek: Add error path for loop of mm_dts_parse > > The mtk_iommu_mm_dts_parse will parse the smi larbs nodes. if the i+1 > larb is parsed fail, we should put_device for the i..0 larbs. > > There are two places need to comment: > 1) The larbid may be not linear mapping, we should loop whole > the array in the error path. > 2) I move this line position: "data->larb_imu[id].dev = &plarbdev->dev;" > before "if (!plarbdev->dev.driver)", That means set > data->larb_imu[id].dev before the error path. then we don't need > "platform_device_put(plarbdev)" again in probe_defer case. All depend > on "put_device" of the error path in error cases. > > Fixes: d2e9a1102cfc ("iommu/mediatek: Contain MM IOMMU flow with the MM TYPE") > Signed-off-by: Yong Wu <yong.wu@mediatek.com> > Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> > Reviewed-by: Matthias Brugger <matthias.bgg@gmail.com> > Link: https://lore.kernel.org/r/20221018024258.19073-4-yong.wu@mediatek.com > Signed-off-by: Joerg Roedel <jroedel@suse.de> > > diff --git a/drivers/iommu/mtk_iommu.c b/drivers/iommu/mtk_iommu.c > index df490236e1fb5..e0c669b75271d 100644 > --- a/drivers/iommu/mtk_iommu.c > +++ b/drivers/iommu/mtk_iommu.c > @@ -1067,8 +1067,10 @@ static int mtk_iommu_mm_dts_parse(struct device *dev, struct component_match **m > u32 id; > > larbnode = of_parse_phandle(dev->of_node, "mediatek,larbs", i); > - if (!larbnode) > - return -EINVAL; > + if (!larbnode) { > + ret = -EINVAL; > + goto err_larbdev_put; > + } > > if (!of_device_is_available(larbnode)) { > of_node_put(larbnode); > @@ -1081,14 +1083,16 @@ static int mtk_iommu_mm_dts_parse(struct device *dev, struct component_match **m > > plarbdev = of_find_device_by_node(larbnode); > of_node_put(larbnode); > - if (!plarbdev) > - return -ENODEV; > + if (!plarbdev) { > + ret = -ENODEV; > + goto err_larbdev_put; > + } > + data->larb_imu[id].dev = &plarbdev->dev; > > if (!plarbdev->dev.driver) { > - platform_device_put(plarbdev); > - return -EPROBE_DEFER; > + ret = -EPROBE_DEFER; > + goto err_larbdev_put; > } > - data->larb_imu[id].dev = &plarbdev->dev; > > component_match_add(dev, match, component_compare_dev, &plarbdev->dev); > platform_device_put(plarbdev); > @@ -1123,6 +1127,15 @@ static int mtk_iommu_mm_dts_parse(struct device *dev, struct component_match **m > return -EINVAL; > } > return 0; > + > +err_larbdev_put: > + /* id may be not linear mapping, loop whole the array */ > + for (i = MTK_LARB_NR_MAX - 1; i >= 0; i++) { > + if (!data->larb_imu[i].dev) > + continue; > + put_device(data->larb_imu[i].dev); > + } > + return ret; > } > > static int mtk_iommu_probe(struct platform_device *pdev) > ------------------------------------------------------------------------------- > > > Git bisection log: > > ------------------------------------------------------------------------------- > git bisect start > # good: [479174d402bcf60789106eedc4def3957c060bad] Merge tag 'platform-drivers-x86-v6.1-5' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86 > git bisect good 479174d402bcf60789106eedc4def3957c060bad > # bad: [f925116b24c0c42dc6d5ab5111c55fd7f74e8dc7] Add linux-next specific files for 20221208 > git bisect bad f925116b24c0c42dc6d5ab5111c55fd7f74e8dc7 > # good: [a1c975859da787104f6f2610f0f5507ef794dea4] Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git > git bisect good a1c975859da787104f6f2610f0f5507ef794dea4 > # bad: [df52ed561d70653b4d82a468026450374161693b] Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git > git bisect bad df52ed561d70653b4d82a468026450374161693b > # good: [ddf1b69a1f2e0704bc0d5f7f71e4f8c4891a3bbb] Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git > git bisect good ddf1b69a1f2e0704bc0d5f7f71e4f8c4891a3bbb > # good: [b5cb3c9818c0085928c1d795e1e2a78add3dbca5] Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git > git bisect good b5cb3c9818c0085928c1d795e1e2a78add3dbca5 > # bad: [b07fcd1e4269638ae72abc499543eb72605bd34b] Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git > git bisect bad b07fcd1e4269638ae72abc499543eb72605bd34b > # bad: [147cf2079e0afce372e3d14089396736a025ecda] Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/pcmoore/audit.git > git bisect bad 147cf2079e0afce372e3d14089396736a025ecda > # good: [14d40e4c74b85c390e076712a6d2831e9464b786] Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/jarkko/linux-tpmdd.git > git bisect good 14d40e4c74b85c390e076712a6d2831e9464b786 > # good: [b169a180bef26679b44484ad24b7d8ae32623a10] iommu/io-pgtable: Remove map/unmap > git bisect good b169a180bef26679b44484ad24b7d8ae32623a10 > # good: [f04ae51dd965bc0b7f2e01c5d85fc214877b4061] Merge tag 'arm-smmu-updates' of git://git.kernel.org/pub/scm/linux/kernel/git/will/linux into arm/smmu > git bisect good f04ae51dd965bc0b7f2e01c5d85fc214877b4061 > # bad: [4dd549a66a969ccd3ed344f37fb9b9e9516fc1e6] Merge branches 'iommu/fixes', 'arm/allwinner', 'arm/exynos', 'arm/mediatek', 'arm/rockchip', 'arm/smmu', 'ppc/pamu', 's390', 'x86/vt-d', 'x86/amd' and 'core' into next > git bisect bad 4dd549a66a969ccd3ed344f37fb9b9e9516fc1e6 > # good: [21c1f9021f0e7d28c3edfcc70e1ca1926ea3774e] s390/pci: use lock-free I/O translation updates > git bisect good 21c1f9021f0e7d28c3edfcc70e1ca1926ea3774e > # bad: [00ef8885a945c37551547d8ac8361cacd20c4e42] iommu/mediatek: Fix crash on isr after kexec() > git bisect bad 00ef8885a945c37551547d8ac8361cacd20c4e42 > # good: [dcb40e9fcce9bd251eaff19f3724131db522846c] iommu/mediatek: Add platform_device_put for recovering the device refcnt > git bisect good dcb40e9fcce9bd251eaff19f3724131db522846c > # bad: [ef693a8440926884bfd9cc3d6d36f65719513350] iommu/mediatek: Validate number of phandles associated with "mediatek,larbs" > git bisect bad ef693a8440926884bfd9cc3d6d36f65719513350 > # bad: [26593928564cf5b576ff05d3cbd958f57c9534bb] iommu/mediatek: Add error path for loop of mm_dts_parse > git bisect bad 26593928564cf5b576ff05d3cbd958f57c9534bb > # good: [b5765a1b44bea9dfcae69c53ffeb4c689d0922a7] iommu/mediatek: Use component_match_add > git bisect good b5765a1b44bea9dfcae69c53ffeb4c689d0922a7 > # first bad commit: [26593928564cf5b576ff05d3cbd958f57c9534bb] iommu/mediatek: Add error path for loop of mm_dts_parse > ------------------------------------------------------------------------------- > > > -=-=-=-=-=-=-=-=-=-=-=- > Groups.io Links: You receive all messages sent to this group. > View/Reply Online (#35262): https://groups.io/g/kernelci-results/message/35262 > Mute This Topic: https://groups.io/mt/95537191/1131744 > Group Owner: kernelci-results+owner@groups.io > Unsubscribe: https://groups.io/g/kernelci-results/unsub [broonie@kernel.org] > -=-=-=-=-=-=-=-=-=-=-=- > > [-- Attachment #1.2: signature.asc --] [-- Type: application/pgp-signature, Size: 488 bytes --] [-- Attachment #2: Type: text/plain, Size: 176 bytes --] _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: next/master bisection: baseline.login on mt8173-elm-hana 2022-12-08 13:48 ` Mark Brown @ 2022-12-16 11:42 ` Matthias Brugger -1 siblings, 0 replies; 8+ messages in thread From: Matthias Brugger @ 2022-12-16 11:42 UTC (permalink / raw) To: Mark Brown, Joerg Roedel, Will Deacon, Yong Wu, kernelci-results, bot, angelogioacchino.delregno Cc: gtucker, iommu, linux-mediatek, linux-arm-kernel, mingyuan.ma, libo.kang, chengci.xu, yf.wang, youlin.pei, anan.sun, xueqi.zhang, Guenter Roeck Yong, Angelo, can you have a look? If not I'd propose to drop the series for now until we understand what is going wrong. Regards, Matthias On 08/12/2022 14:48, Mark Brown wrote: > On Thu, Dec 08, 2022 at 05:08:20AM -0800, KernelCI bot wrote: > > The KernelCI bisection bot found a boot failure in today's -next on > mt8173-elm-hana was triggered by 26593928564cf ("iommu/mediatek: Add > error path for loop of mm_dts_parse"). We get an oops towards the end > of boot: > > <6>[ 0.840037] printk: bootconsole [mtk8250] disabled > <6>[ 0.840037] printk: bootconsole [mtk8250] disabled > <1>[ 0.854924] Unable to handle kernel read from unreadable memory at virtual address 000000000000003b > > <1>[ 0.864288] Mem abort info: > <1>[ 0.867374] ESR = 0x0000000096000005 > <1>[ 0.871408] EC = 0x25: DABT (current EL), IL = 32 bits > <1>[ 0.877005] SET = 0, FnV = 0 > <1>[ 0.880350] EA = 0, S1PTW = 0 > <1>[ 0.883776] FSC = 0x05: level 1 translation fault > <1>[ 0.888938] Data abort info: > > ... > > <4>[ 1.027320] kobject_put+0x18/0xf0 > <4>[ 1.030996] put_device+0x1c/0x28 > > <4>[ 1.034586] mtk_iommu_mm_dts_parse+0x2d0/0x31c > <4>[ 1.039394] mtk_iommu_probe+0x2dc/0x4c0 > <4>[ 1.043592] platform_probe+0xb0/0xd0 > <4>[ 1.047530] really_probe+0xf8/0x280 > <4>[ 1.051377] __driver_probe_device+0xbc/0xe8 > > <4>[ 1.055923] driver_probe_device+0x44/0x104 > <4>[ 1.060380] __driver_attach+0xb4/0x108 > <4>[ 1.064487] bus_for_each_dev+0x88/0xd4 > <4>[ 1.068598] driver_attach+0x2c/0x38 > <4>[ 1.072445] bus_add_driver+0x114/0x1f4 > <4>[ 1.076554] driver_register+0x6c/0x108 > <4>[ 1.080663] __platform_driver_register+0x2c/0x38 > <4>[ 1.085640] mtk_iommu_driver_init+0x24/0x30 > > I've left the full report from the bot below, including links to more > detailed information and a Reported-by tag for the bot below, the log > links got mangled and should be: > > https://storage.kernelci.org/next/master/next-20221208/arm64/cros---chromeos-5.10-arm64-chromiumos-mediatek.flavour.config%2Barm64-chromebook/clang-13/lab-collabora/baseline-mt8173-elm-hana.html > https://storage.kernelci.org/next/master/next-20221208/arm64/cros---chromeos-5.10-arm64-chromiumos-mediatek.flavour.config%2Barm64-chromebook/clang-13/lab-collabora/baseline-mt8173-elm-hana.txt > >> * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * >> * This automated bisection report was sent to you on the basis * >> * that you may be involved with the breaking commit it has * >> * found. No manual investigation has been done to verify it, * >> * and the root cause of the problem may be somewhere else. * >> * * >> * If you do send a fix, please include this trailer: * >> * Reported-by: "kernelci.org bot" <bot@kernelci.org> * >> * * >> * Hope this helps! * >> * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * >> >> next/master bisection: baseline.login on mt8173-elm-hana >> >> Summary: >> Start: f925116b24c0c Add linux-next specific files for 20221208 >> Plain log: https://storage.kernelci.org/next/master/next-20221208/arm64/cros://chromeos-5.10/arm64/chromiumos-arm64.flavour.config+arm64-chromebook/clang-13/lab-collabora/baseline-mt8173-elm-hana.txt >> HTML log: https://storage.kernelci.org/next/master/next-20221208/arm64/cros://chromeos-5.10/arm64/chromiumos-arm64.flavour.config+arm64-chromebook/clang-13/lab-collabora/baseline-mt8173-elm-hana.html >> Result: 26593928564cf iommu/mediatek: Add error path for loop of mm_dts_parse >> >> Checks: >> revert: PASS >> verify: PASS >> >> Parameters: >> Tree: next >> URL: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git >> Branch: master >> Target: mt8173-elm-hana >> CPU arch: arm64 >> Lab: lab-collabora >> Compiler: clang-13 >> Config: cros://chromeos-5.10/arm64/chromiumos-arm64.flavour.config+arm64-chromebook >> Test case: baseline.login >> >> Breaking commit found: >> >> ------------------------------------------------------------------------------- >> commit 26593928564cf5b576ff05d3cbd958f57c9534bb >> Author: Yong Wu <yong.wu@mediatek.com> >> Date: Tue Oct 18 10:42:55 2022 +0800 >> >> iommu/mediatek: Add error path for loop of mm_dts_parse >> >> The mtk_iommu_mm_dts_parse will parse the smi larbs nodes. if the i+1 >> larb is parsed fail, we should put_device for the i..0 larbs. >> >> There are two places need to comment: >> 1) The larbid may be not linear mapping, we should loop whole >> the array in the error path. >> 2) I move this line position: "data->larb_imu[id].dev = &plarbdev->dev;" >> before "if (!plarbdev->dev.driver)", That means set >> data->larb_imu[id].dev before the error path. then we don't need >> "platform_device_put(plarbdev)" again in probe_defer case. All depend >> on "put_device" of the error path in error cases. >> >> Fixes: d2e9a1102cfc ("iommu/mediatek: Contain MM IOMMU flow with the MM TYPE") >> Signed-off-by: Yong Wu <yong.wu@mediatek.com> >> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> >> Reviewed-by: Matthias Brugger <matthias.bgg@gmail.com> >> Link: https://lore.kernel.org/r/20221018024258.19073-4-yong.wu@mediatek.com >> Signed-off-by: Joerg Roedel <jroedel@suse.de> >> >> diff --git a/drivers/iommu/mtk_iommu.c b/drivers/iommu/mtk_iommu.c >> index df490236e1fb5..e0c669b75271d 100644 >> --- a/drivers/iommu/mtk_iommu.c >> +++ b/drivers/iommu/mtk_iommu.c >> @@ -1067,8 +1067,10 @@ static int mtk_iommu_mm_dts_parse(struct device *dev, struct component_match **m >> u32 id; >> >> larbnode = of_parse_phandle(dev->of_node, "mediatek,larbs", i); >> - if (!larbnode) >> - return -EINVAL; >> + if (!larbnode) { >> + ret = -EINVAL; >> + goto err_larbdev_put; >> + } >> >> if (!of_device_is_available(larbnode)) { >> of_node_put(larbnode); >> @@ -1081,14 +1083,16 @@ static int mtk_iommu_mm_dts_parse(struct device *dev, struct component_match **m >> >> plarbdev = of_find_device_by_node(larbnode); >> of_node_put(larbnode); >> - if (!plarbdev) >> - return -ENODEV; >> + if (!plarbdev) { >> + ret = -ENODEV; >> + goto err_larbdev_put; >> + } >> + data->larb_imu[id].dev = &plarbdev->dev; >> >> if (!plarbdev->dev.driver) { >> - platform_device_put(plarbdev); >> - return -EPROBE_DEFER; >> + ret = -EPROBE_DEFER; >> + goto err_larbdev_put; >> } >> - data->larb_imu[id].dev = &plarbdev->dev; >> >> component_match_add(dev, match, component_compare_dev, &plarbdev->dev); >> platform_device_put(plarbdev); >> @@ -1123,6 +1127,15 @@ static int mtk_iommu_mm_dts_parse(struct device *dev, struct component_match **m >> return -EINVAL; >> } >> return 0; >> + >> +err_larbdev_put: >> + /* id may be not linear mapping, loop whole the array */ >> + for (i = MTK_LARB_NR_MAX - 1; i >= 0; i++) { >> + if (!data->larb_imu[i].dev) >> + continue; >> + put_device(data->larb_imu[i].dev); >> + } >> + return ret; >> } >> >> static int mtk_iommu_probe(struct platform_device *pdev) >> ------------------------------------------------------------------------------- >> >> >> Git bisection log: >> >> ------------------------------------------------------------------------------- >> git bisect start >> # good: [479174d402bcf60789106eedc4def3957c060bad] Merge tag 'platform-drivers-x86-v6.1-5' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86 >> git bisect good 479174d402bcf60789106eedc4def3957c060bad >> # bad: [f925116b24c0c42dc6d5ab5111c55fd7f74e8dc7] Add linux-next specific files for 20221208 >> git bisect bad f925116b24c0c42dc6d5ab5111c55fd7f74e8dc7 >> # good: [a1c975859da787104f6f2610f0f5507ef794dea4] Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git >> git bisect good a1c975859da787104f6f2610f0f5507ef794dea4 >> # bad: [df52ed561d70653b4d82a468026450374161693b] Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git >> git bisect bad df52ed561d70653b4d82a468026450374161693b >> # good: [ddf1b69a1f2e0704bc0d5f7f71e4f8c4891a3bbb] Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git >> git bisect good ddf1b69a1f2e0704bc0d5f7f71e4f8c4891a3bbb >> # good: [b5cb3c9818c0085928c1d795e1e2a78add3dbca5] Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git >> git bisect good b5cb3c9818c0085928c1d795e1e2a78add3dbca5 >> # bad: [b07fcd1e4269638ae72abc499543eb72605bd34b] Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git >> git bisect bad b07fcd1e4269638ae72abc499543eb72605bd34b >> # bad: [147cf2079e0afce372e3d14089396736a025ecda] Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/pcmoore/audit.git >> git bisect bad 147cf2079e0afce372e3d14089396736a025ecda >> # good: [14d40e4c74b85c390e076712a6d2831e9464b786] Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/jarkko/linux-tpmdd.git >> git bisect good 14d40e4c74b85c390e076712a6d2831e9464b786 >> # good: [b169a180bef26679b44484ad24b7d8ae32623a10] iommu/io-pgtable: Remove map/unmap >> git bisect good b169a180bef26679b44484ad24b7d8ae32623a10 >> # good: [f04ae51dd965bc0b7f2e01c5d85fc214877b4061] Merge tag 'arm-smmu-updates' of git://git.kernel.org/pub/scm/linux/kernel/git/will/linux into arm/smmu >> git bisect good f04ae51dd965bc0b7f2e01c5d85fc214877b4061 >> # bad: [4dd549a66a969ccd3ed344f37fb9b9e9516fc1e6] Merge branches 'iommu/fixes', 'arm/allwinner', 'arm/exynos', 'arm/mediatek', 'arm/rockchip', 'arm/smmu', 'ppc/pamu', 's390', 'x86/vt-d', 'x86/amd' and 'core' into next >> git bisect bad 4dd549a66a969ccd3ed344f37fb9b9e9516fc1e6 >> # good: [21c1f9021f0e7d28c3edfcc70e1ca1926ea3774e] s390/pci: use lock-free I/O translation updates >> git bisect good 21c1f9021f0e7d28c3edfcc70e1ca1926ea3774e >> # bad: [00ef8885a945c37551547d8ac8361cacd20c4e42] iommu/mediatek: Fix crash on isr after kexec() >> git bisect bad 00ef8885a945c37551547d8ac8361cacd20c4e42 >> # good: [dcb40e9fcce9bd251eaff19f3724131db522846c] iommu/mediatek: Add platform_device_put for recovering the device refcnt >> git bisect good dcb40e9fcce9bd251eaff19f3724131db522846c >> # bad: [ef693a8440926884bfd9cc3d6d36f65719513350] iommu/mediatek: Validate number of phandles associated with "mediatek,larbs" >> git bisect bad ef693a8440926884bfd9cc3d6d36f65719513350 >> # bad: [26593928564cf5b576ff05d3cbd958f57c9534bb] iommu/mediatek: Add error path for loop of mm_dts_parse >> git bisect bad 26593928564cf5b576ff05d3cbd958f57c9534bb >> # good: [b5765a1b44bea9dfcae69c53ffeb4c689d0922a7] iommu/mediatek: Use component_match_add >> git bisect good b5765a1b44bea9dfcae69c53ffeb4c689d0922a7 >> # first bad commit: [26593928564cf5b576ff05d3cbd958f57c9534bb] iommu/mediatek: Add error path for loop of mm_dts_parse >> ------------------------------------------------------------------------------- >> >> >> -=-=-=-=-=-=-=-=-=-=-=- >> Groups.io Links: You receive all messages sent to this group. >> View/Reply Online (#35262): https://groups.io/g/kernelci-results/message/35262 >> Mute This Topic: https://groups.io/mt/95537191/1131744 >> Group Owner: kernelci-results+owner@groups.io >> Unsubscribe: https://groups.io/g/kernelci-results/unsub [broonie@kernel.org] >> -=-=-=-=-=-=-=-=-=-=-=- >> >> ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: next/master bisection: baseline.login on mt8173-elm-hana @ 2022-12-16 11:42 ` Matthias Brugger 0 siblings, 0 replies; 8+ messages in thread From: Matthias Brugger @ 2022-12-16 11:42 UTC (permalink / raw) To: Mark Brown, Joerg Roedel, Will Deacon, Yong Wu, kernelci-results, bot, angelogioacchino.delregno Cc: gtucker, iommu, linux-mediatek, linux-arm-kernel, mingyuan.ma, libo.kang, chengci.xu, yf.wang, youlin.pei, anan.sun, xueqi.zhang, Guenter Roeck Yong, Angelo, can you have a look? If not I'd propose to drop the series for now until we understand what is going wrong. Regards, Matthias On 08/12/2022 14:48, Mark Brown wrote: > On Thu, Dec 08, 2022 at 05:08:20AM -0800, KernelCI bot wrote: > > The KernelCI bisection bot found a boot failure in today's -next on > mt8173-elm-hana was triggered by 26593928564cf ("iommu/mediatek: Add > error path for loop of mm_dts_parse"). We get an oops towards the end > of boot: > > <6>[ 0.840037] printk: bootconsole [mtk8250] disabled > <6>[ 0.840037] printk: bootconsole [mtk8250] disabled > <1>[ 0.854924] Unable to handle kernel read from unreadable memory at virtual address 000000000000003b > > <1>[ 0.864288] Mem abort info: > <1>[ 0.867374] ESR = 0x0000000096000005 > <1>[ 0.871408] EC = 0x25: DABT (current EL), IL = 32 bits > <1>[ 0.877005] SET = 0, FnV = 0 > <1>[ 0.880350] EA = 0, S1PTW = 0 > <1>[ 0.883776] FSC = 0x05: level 1 translation fault > <1>[ 0.888938] Data abort info: > > ... > > <4>[ 1.027320] kobject_put+0x18/0xf0 > <4>[ 1.030996] put_device+0x1c/0x28 > > <4>[ 1.034586] mtk_iommu_mm_dts_parse+0x2d0/0x31c > <4>[ 1.039394] mtk_iommu_probe+0x2dc/0x4c0 > <4>[ 1.043592] platform_probe+0xb0/0xd0 > <4>[ 1.047530] really_probe+0xf8/0x280 > <4>[ 1.051377] __driver_probe_device+0xbc/0xe8 > > <4>[ 1.055923] driver_probe_device+0x44/0x104 > <4>[ 1.060380] __driver_attach+0xb4/0x108 > <4>[ 1.064487] bus_for_each_dev+0x88/0xd4 > <4>[ 1.068598] driver_attach+0x2c/0x38 > <4>[ 1.072445] bus_add_driver+0x114/0x1f4 > <4>[ 1.076554] driver_register+0x6c/0x108 > <4>[ 1.080663] __platform_driver_register+0x2c/0x38 > <4>[ 1.085640] mtk_iommu_driver_init+0x24/0x30 > > I've left the full report from the bot below, including links to more > detailed information and a Reported-by tag for the bot below, the log > links got mangled and should be: > > https://storage.kernelci.org/next/master/next-20221208/arm64/cros---chromeos-5.10-arm64-chromiumos-mediatek.flavour.config%2Barm64-chromebook/clang-13/lab-collabora/baseline-mt8173-elm-hana.html > https://storage.kernelci.org/next/master/next-20221208/arm64/cros---chromeos-5.10-arm64-chromiumos-mediatek.flavour.config%2Barm64-chromebook/clang-13/lab-collabora/baseline-mt8173-elm-hana.txt > >> * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * >> * This automated bisection report was sent to you on the basis * >> * that you may be involved with the breaking commit it has * >> * found. No manual investigation has been done to verify it, * >> * and the root cause of the problem may be somewhere else. * >> * * >> * If you do send a fix, please include this trailer: * >> * Reported-by: "kernelci.org bot" <bot@kernelci.org> * >> * * >> * Hope this helps! * >> * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * >> >> next/master bisection: baseline.login on mt8173-elm-hana >> >> Summary: >> Start: f925116b24c0c Add linux-next specific files for 20221208 >> Plain log: https://storage.kernelci.org/next/master/next-20221208/arm64/cros://chromeos-5.10/arm64/chromiumos-arm64.flavour.config+arm64-chromebook/clang-13/lab-collabora/baseline-mt8173-elm-hana.txt >> HTML log: https://storage.kernelci.org/next/master/next-20221208/arm64/cros://chromeos-5.10/arm64/chromiumos-arm64.flavour.config+arm64-chromebook/clang-13/lab-collabora/baseline-mt8173-elm-hana.html >> Result: 26593928564cf iommu/mediatek: Add error path for loop of mm_dts_parse >> >> Checks: >> revert: PASS >> verify: PASS >> >> Parameters: >> Tree: next >> URL: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git >> Branch: master >> Target: mt8173-elm-hana >> CPU arch: arm64 >> Lab: lab-collabora >> Compiler: clang-13 >> Config: cros://chromeos-5.10/arm64/chromiumos-arm64.flavour.config+arm64-chromebook >> Test case: baseline.login >> >> Breaking commit found: >> >> ------------------------------------------------------------------------------- >> commit 26593928564cf5b576ff05d3cbd958f57c9534bb >> Author: Yong Wu <yong.wu@mediatek.com> >> Date: Tue Oct 18 10:42:55 2022 +0800 >> >> iommu/mediatek: Add error path for loop of mm_dts_parse >> >> The mtk_iommu_mm_dts_parse will parse the smi larbs nodes. if the i+1 >> larb is parsed fail, we should put_device for the i..0 larbs. >> >> There are two places need to comment: >> 1) The larbid may be not linear mapping, we should loop whole >> the array in the error path. >> 2) I move this line position: "data->larb_imu[id].dev = &plarbdev->dev;" >> before "if (!plarbdev->dev.driver)", That means set >> data->larb_imu[id].dev before the error path. then we don't need >> "platform_device_put(plarbdev)" again in probe_defer case. All depend >> on "put_device" of the error path in error cases. >> >> Fixes: d2e9a1102cfc ("iommu/mediatek: Contain MM IOMMU flow with the MM TYPE") >> Signed-off-by: Yong Wu <yong.wu@mediatek.com> >> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> >> Reviewed-by: Matthias Brugger <matthias.bgg@gmail.com> >> Link: https://lore.kernel.org/r/20221018024258.19073-4-yong.wu@mediatek.com >> Signed-off-by: Joerg Roedel <jroedel@suse.de> >> >> diff --git a/drivers/iommu/mtk_iommu.c b/drivers/iommu/mtk_iommu.c >> index df490236e1fb5..e0c669b75271d 100644 >> --- a/drivers/iommu/mtk_iommu.c >> +++ b/drivers/iommu/mtk_iommu.c >> @@ -1067,8 +1067,10 @@ static int mtk_iommu_mm_dts_parse(struct device *dev, struct component_match **m >> u32 id; >> >> larbnode = of_parse_phandle(dev->of_node, "mediatek,larbs", i); >> - if (!larbnode) >> - return -EINVAL; >> + if (!larbnode) { >> + ret = -EINVAL; >> + goto err_larbdev_put; >> + } >> >> if (!of_device_is_available(larbnode)) { >> of_node_put(larbnode); >> @@ -1081,14 +1083,16 @@ static int mtk_iommu_mm_dts_parse(struct device *dev, struct component_match **m >> >> plarbdev = of_find_device_by_node(larbnode); >> of_node_put(larbnode); >> - if (!plarbdev) >> - return -ENODEV; >> + if (!plarbdev) { >> + ret = -ENODEV; >> + goto err_larbdev_put; >> + } >> + data->larb_imu[id].dev = &plarbdev->dev; >> >> if (!plarbdev->dev.driver) { >> - platform_device_put(plarbdev); >> - return -EPROBE_DEFER; >> + ret = -EPROBE_DEFER; >> + goto err_larbdev_put; >> } >> - data->larb_imu[id].dev = &plarbdev->dev; >> >> component_match_add(dev, match, component_compare_dev, &plarbdev->dev); >> platform_device_put(plarbdev); >> @@ -1123,6 +1127,15 @@ static int mtk_iommu_mm_dts_parse(struct device *dev, struct component_match **m >> return -EINVAL; >> } >> return 0; >> + >> +err_larbdev_put: >> + /* id may be not linear mapping, loop whole the array */ >> + for (i = MTK_LARB_NR_MAX - 1; i >= 0; i++) { >> + if (!data->larb_imu[i].dev) >> + continue; >> + put_device(data->larb_imu[i].dev); >> + } >> + return ret; >> } >> >> static int mtk_iommu_probe(struct platform_device *pdev) >> ------------------------------------------------------------------------------- >> >> >> Git bisection log: >> >> ------------------------------------------------------------------------------- >> git bisect start >> # good: [479174d402bcf60789106eedc4def3957c060bad] Merge tag 'platform-drivers-x86-v6.1-5' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86 >> git bisect good 479174d402bcf60789106eedc4def3957c060bad >> # bad: [f925116b24c0c42dc6d5ab5111c55fd7f74e8dc7] Add linux-next specific files for 20221208 >> git bisect bad f925116b24c0c42dc6d5ab5111c55fd7f74e8dc7 >> # good: [a1c975859da787104f6f2610f0f5507ef794dea4] Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git >> git bisect good a1c975859da787104f6f2610f0f5507ef794dea4 >> # bad: [df52ed561d70653b4d82a468026450374161693b] Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git >> git bisect bad df52ed561d70653b4d82a468026450374161693b >> # good: [ddf1b69a1f2e0704bc0d5f7f71e4f8c4891a3bbb] Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git >> git bisect good ddf1b69a1f2e0704bc0d5f7f71e4f8c4891a3bbb >> # good: [b5cb3c9818c0085928c1d795e1e2a78add3dbca5] Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git >> git bisect good b5cb3c9818c0085928c1d795e1e2a78add3dbca5 >> # bad: [b07fcd1e4269638ae72abc499543eb72605bd34b] Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git >> git bisect bad b07fcd1e4269638ae72abc499543eb72605bd34b >> # bad: [147cf2079e0afce372e3d14089396736a025ecda] Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/pcmoore/audit.git >> git bisect bad 147cf2079e0afce372e3d14089396736a025ecda >> # good: [14d40e4c74b85c390e076712a6d2831e9464b786] Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/jarkko/linux-tpmdd.git >> git bisect good 14d40e4c74b85c390e076712a6d2831e9464b786 >> # good: [b169a180bef26679b44484ad24b7d8ae32623a10] iommu/io-pgtable: Remove map/unmap >> git bisect good b169a180bef26679b44484ad24b7d8ae32623a10 >> # good: [f04ae51dd965bc0b7f2e01c5d85fc214877b4061] Merge tag 'arm-smmu-updates' of git://git.kernel.org/pub/scm/linux/kernel/git/will/linux into arm/smmu >> git bisect good f04ae51dd965bc0b7f2e01c5d85fc214877b4061 >> # bad: [4dd549a66a969ccd3ed344f37fb9b9e9516fc1e6] Merge branches 'iommu/fixes', 'arm/allwinner', 'arm/exynos', 'arm/mediatek', 'arm/rockchip', 'arm/smmu', 'ppc/pamu', 's390', 'x86/vt-d', 'x86/amd' and 'core' into next >> git bisect bad 4dd549a66a969ccd3ed344f37fb9b9e9516fc1e6 >> # good: [21c1f9021f0e7d28c3edfcc70e1ca1926ea3774e] s390/pci: use lock-free I/O translation updates >> git bisect good 21c1f9021f0e7d28c3edfcc70e1ca1926ea3774e >> # bad: [00ef8885a945c37551547d8ac8361cacd20c4e42] iommu/mediatek: Fix crash on isr after kexec() >> git bisect bad 00ef8885a945c37551547d8ac8361cacd20c4e42 >> # good: [dcb40e9fcce9bd251eaff19f3724131db522846c] iommu/mediatek: Add platform_device_put for recovering the device refcnt >> git bisect good dcb40e9fcce9bd251eaff19f3724131db522846c >> # bad: [ef693a8440926884bfd9cc3d6d36f65719513350] iommu/mediatek: Validate number of phandles associated with "mediatek,larbs" >> git bisect bad ef693a8440926884bfd9cc3d6d36f65719513350 >> # bad: [26593928564cf5b576ff05d3cbd958f57c9534bb] iommu/mediatek: Add error path for loop of mm_dts_parse >> git bisect bad 26593928564cf5b576ff05d3cbd958f57c9534bb >> # good: [b5765a1b44bea9dfcae69c53ffeb4c689d0922a7] iommu/mediatek: Use component_match_add >> git bisect good b5765a1b44bea9dfcae69c53ffeb4c689d0922a7 >> # first bad commit: [26593928564cf5b576ff05d3cbd958f57c9534bb] iommu/mediatek: Add error path for loop of mm_dts_parse >> ------------------------------------------------------------------------------- >> >> >> -=-=-=-=-=-=-=-=-=-=-=- >> Groups.io Links: You receive all messages sent to this group. >> View/Reply Online (#35262): https://groups.io/g/kernelci-results/message/35262 >> Mute This Topic: https://groups.io/mt/95537191/1131744 >> Group Owner: kernelci-results+owner@groups.io >> Unsubscribe: https://groups.io/g/kernelci-results/unsub [broonie@kernel.org] >> -=-=-=-=-=-=-=-=-=-=-=- >> >> _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: next/master bisection: baseline.login on mt8173-elm-hana 2022-12-16 11:42 ` Matthias Brugger @ 2022-12-16 11:44 ` AngeloGioacchino Del Regno -1 siblings, 0 replies; 8+ messages in thread From: AngeloGioacchino Del Regno @ 2022-12-16 11:44 UTC (permalink / raw) To: Matthias Brugger, Mark Brown, Joerg Roedel, Will Deacon, Yong Wu, kernelci-results, bot Cc: gtucker, iommu, linux-mediatek, linux-arm-kernel, mingyuan.ma, libo.kang, chengci.xu, yf.wang, youlin.pei, anan.sun, xueqi.zhang, Guenter Roeck Il 16/12/22 12:42, Matthias Brugger ha scritto: > Yong, Angelo, can you have a look? > > If not I'd propose to drop the series for now until we understand what is going wrong. > > Regards, > Matthias > It's fixed already, and picked upstream [1]... that was happening on more than just MT8173! :-) [1]: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/drivers/iommu/mtk_iommu.c?h=next-20221216&id=462e768b55a2331324ff72e74706261134369826 Cheers, Angelo ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: next/master bisection: baseline.login on mt8173-elm-hana @ 2022-12-16 11:44 ` AngeloGioacchino Del Regno 0 siblings, 0 replies; 8+ messages in thread From: AngeloGioacchino Del Regno @ 2022-12-16 11:44 UTC (permalink / raw) To: Matthias Brugger, Mark Brown, Joerg Roedel, Will Deacon, Yong Wu, kernelci-results, bot Cc: gtucker, iommu, linux-mediatek, linux-arm-kernel, mingyuan.ma, libo.kang, chengci.xu, yf.wang, youlin.pei, anan.sun, xueqi.zhang, Guenter Roeck Il 16/12/22 12:42, Matthias Brugger ha scritto: > Yong, Angelo, can you have a look? > > If not I'd propose to drop the series for now until we understand what is going wrong. > > Regards, > Matthias > It's fixed already, and picked upstream [1]... that was happening on more than just MT8173! :-) [1]: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/drivers/iommu/mtk_iommu.c?h=next-20221216&id=462e768b55a2331324ff72e74706261134369826 Cheers, Angelo _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: next/master bisection: baseline.login on mt8173-elm-hana 2022-12-16 11:44 ` AngeloGioacchino Del Regno @ 2022-12-16 12:21 ` Matthias Brugger -1 siblings, 0 replies; 8+ messages in thread From: Matthias Brugger @ 2022-12-16 12:21 UTC (permalink / raw) To: AngeloGioacchino Del Regno, Mark Brown, Joerg Roedel, Will Deacon, Yong Wu, kernelci-results, bot Cc: gtucker, iommu, linux-mediatek, linux-arm-kernel, mingyuan.ma, libo.kang, chengci.xu, yf.wang, youlin.pei, anan.sun, xueqi.zhang, Guenter Roeck On 16/12/2022 12:44, AngeloGioacchino Del Regno wrote: > Il 16/12/22 12:42, Matthias Brugger ha scritto: >> Yong, Angelo, can you have a look? >> >> If not I'd propose to drop the series for now until we understand what is >> going wrong. >> >> Regards, >> Matthias >> > > It's fixed already, and picked upstream [1]... that was happening on more than > just MT8173! :-) > > [1]: > https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/drivers/iommu/mtk_iommu.c?h=next-20221216&id=462e768b55a2331324ff72e74706261134369826 > Ah saw that patch today and marked to look into it later. Perfect, one thing less to care about :) ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: next/master bisection: baseline.login on mt8173-elm-hana @ 2022-12-16 12:21 ` Matthias Brugger 0 siblings, 0 replies; 8+ messages in thread From: Matthias Brugger @ 2022-12-16 12:21 UTC (permalink / raw) To: AngeloGioacchino Del Regno, Mark Brown, Joerg Roedel, Will Deacon, Yong Wu, kernelci-results, bot Cc: gtucker, iommu, linux-mediatek, linux-arm-kernel, mingyuan.ma, libo.kang, chengci.xu, yf.wang, youlin.pei, anan.sun, xueqi.zhang, Guenter Roeck On 16/12/2022 12:44, AngeloGioacchino Del Regno wrote: > Il 16/12/22 12:42, Matthias Brugger ha scritto: >> Yong, Angelo, can you have a look? >> >> If not I'd propose to drop the series for now until we understand what is >> going wrong. >> >> Regards, >> Matthias >> > > It's fixed already, and picked upstream [1]... that was happening on more than > just MT8173! :-) > > [1]: > https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/drivers/iommu/mtk_iommu.c?h=next-20221216&id=462e768b55a2331324ff72e74706261134369826 > Ah saw that patch today and marked to look into it later. Perfect, one thing less to care about :) _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel ^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2022-12-16 12:22 UTC | newest] Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- [not found] <6391e1c4.170a0220.b562d.3c9c@mx.google.com> 2022-12-08 13:48 ` next/master bisection: baseline.login on mt8173-elm-hana Mark Brown 2022-12-08 13:48 ` Mark Brown 2022-12-16 11:42 ` Matthias Brugger 2022-12-16 11:42 ` Matthias Brugger 2022-12-16 11:44 ` AngeloGioacchino Del Regno 2022-12-16 11:44 ` AngeloGioacchino Del Regno 2022-12-16 12:21 ` Matthias Brugger 2022-12-16 12:21 ` Matthias Brugger
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.