)]}'
{
  "commit": "220175cd3979fdb860decf757cc7a5980fdd045f",
  "tree": "78b44c05a97d971ece857dd562e35cc88664489f",
  "parents": [
    "f2644bd7413c8f2fcef208c576e83335709c5120"
  ],
  "author": {
    "name": "Dong Aisheng",
    "email": "aisheng.dong@nxp.com",
    "time": "Fri Oct 30 23:37:33 2020 +0800"
  },
  "committer": {
    "name": "Shawn Guo",
    "email": "shawnguo@kernel.org",
    "time": "Tue Nov 03 07:35:47 2020 +0800"
  },
  "message": "clk: imx: scu: fix build break when compiled as modules\n\nAfter commit e0d0d4d86c76 (\"clk: imx8qxp: Support building i.MX8QXP clock\ndriver as module\"), clk-scu.c and clk-imx8qxp.c are complied in one module,\nthus there can be only one module_init() in those two files.\nCommit 77d8f3068c63 (\"clk: imx: scu: add two cells binding support\")\nintroduced another module_init() in clk_scu.c which caused the errors\nbelow.\n\nTo fix the issue, we can remove the unnecessary builtin_platform_driver\nfrom clk_scu.c and directly register the driver in imx_clk_scu_init().\n\n  CC [M]  drivers/clk/imx/clk-scu.o\nIn file included from ../include/linux/of_device.h:6,\n                 from ../include/linux/of_platform.h:12,\n                 from ../drivers/clk/imx/clk-scu.c:11:\n../drivers/clk/imx/clk-scu.c: In function ‘imx_clk_scu_init’:\n../drivers/clk/imx/clk-scu.c:176:35: error: ‘imx_clk_scu_driver’ undeclared (first use in this function); did you mean ‘imx_clk_scu_init’?\n  176 |  return platform_driver_register(\u0026imx_clk_scu_driver);\n      |                                   ^~~~~~~~~~~~~~~~~~\n../include/linux/platform_device.h:218:29: note: in definition of macro ‘platform_driver_register’\n  218 |  __platform_driver_register(drv, THIS_MODULE)\n      |                             ^~~\n../drivers/clk/imx/clk-scu.c:176:35: note: each undeclared identifier is reported only once for each function it appears in\n  176 |  return platform_driver_register(\u0026imx_clk_scu_driver);\n      |                                   ^~~~~~~~~~~~~~~~~~\n../include/linux/platform_device.h:218:29: note: in definition of macro ‘platform_driver_register’\n  218 |  __platform_driver_register(drv, THIS_MODULE)\n      |                             ^~~\n../drivers/clk/imx/clk-scu.c:177:1: error: control reaches end of non-void function [-Werror\u003dreturn-type]\n  177 | }\n      | ^\nAt top level:\n../drivers/clk/imx/clk-scu.c:470:31: warning: ‘imx_clk_scu_driver’ defined but not used [-Wunused-variable]\n  470 | static struct platform_driver imx_clk_scu_driver \u003d {\n\nReported-by: kernel test robot \u003clkp@intel.com\u003e\nFixes: 77d8f3068c63 (\"clk: imx: scu: add two cells binding support\")\nSigned-off-by: Dong Aisheng \u003caisheng.dong@nxp.com\u003e\nAcked-by: Stephen Boyd \u003csboyd@kernel.org\u003e\nSigned-off-by: Shawn Guo \u003cshawnguo@kernel.org\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "229a290ca5b6848f013068da0dabcdcc17f73345",
      "old_mode": 33188,
      "old_path": "drivers/clk/imx/clk-scu.c",
      "new_id": "d0243c52ccbcf5ce0321c769780ebb59e0661949",
      "new_mode": 33188,
      "new_path": "drivers/clk/imx/clk-scu.c"
    }
  ]
}
