14 Nov, 2018

1 commit

  • commit d5269c4553a64b6882f2c019ae21b783a0984a83 upstream.

    In the case that the interrupts fail to result because of the
    interrupt-controller not yet being registered the
    platform_get_irq_byname() call will fail with -EPROBE_DEFER, but passing
    this into devm_request_threaded_irq() will result in -EINVAL being
    returned, the driver is therefor not reprobed later.

    Fixes: 3b415c8fb263 ("remoteproc: q6v5: Extract common resource handling")
    Cc: stable@vger.kernel.org
    Reviewed-by: Sibi Sankar
    Signed-off-by: Bjorn Andersson
    Signed-off-by: Greg Kroah-Hartman

    Bjorn Andersson
     

17 Aug, 2018

1 commit


14 Aug, 2018

1 commit


31 Jul, 2018

4 commits

  • The format specifier "%p" can leak kernel addresses.
    Use "%pK" instead.

    Signed-off-by: Loic Pallardy
    Signed-off-by: Bjorn Andersson

    Loic Pallardy
     
  • The format specifier "%p" can leak kernel addresses.
    Use "%pK" instead.

    This patch proposes changes for remoteproc core only.

    Acked-by: Suman Anna
    Signed-off-by: Loic Pallardy
    Signed-off-by: Bjorn Andersson

    Loic Pallardy
     
  • A new driver got added that depends on QCOM_SMD and fails to link
    as built-in with CONFIG_QCOM_SMD=m:

    drivers/remoteproc/qcom_common.o: In function `smd_subdev_stop':
    qcom_common.c:(.text+0x674): undefined reference to `qcom_smd_unregister_edge'
    drivers/remoteproc/qcom_common.o: In function `smd_subdev_start':
    qcom_common.c:(.text+0x700): undefined reference to `qcom_smd_register_edge'

    We've fixed the same thing several times before, so use the same
    dependency here.

    Fixes: 3a3d4163e0bf ("remoteproc: qcom: Introduce Hexagon V5 based WCSS driver")
    Acked-by: Sricharan R
    Signed-off-by: Arnd Bergmann
    Signed-off-by: Bjorn Andersson

    Arnd Bergmann
     
  • Unwind the modified table_ptr and restore it to the local copy
    upon any subsequent failures in the rproc_start() function. This
    keeps the function to remain balanced on failures without the need
    to balance any modified variables elsewhere.

    While at this, do some minor cleanup of the extra lines between
    the failure labels as well.

    Signed-off-by: Suman Anna
    [bjorn: unconditionally set table_ptr to cached_table]
    Signed-off-by: Bjorn Andersson

    Suman Anna
     

11 Jul, 2018

2 commits

  • GCC_MSS_AXIS2 clock is used for disabling boot IMEM (a part of
    AP boot up). With Boot IMEM disable now a part TZ/ATF, AXIS2
    clock is no longer required post AP boot up and expected to
    remain untouched. However if the clock is turned ON after Q6
    is brought out of reset and later turned off, it results in
    modem hang. When Q6 attempts a power collapse the internal
    handshaking to check if AXIS2 is idle never goes through since
    it is turned off preventing the RSC from getting triggered,
    leaving modem in a funky state. Hence removing AXIS2 clk
    enable/disable from the driver.

    Reported-by: Bjorn Andersson
    Signed-off-by: Sibi Sankar
    Signed-off-by: Bjorn Andersson

    Sibi Sankar
     
  • The new driver only works as built-in code at the moment but fails
    with a link error when configured as a loadable module:

    WARNING: modpost: missing MODULE_LICENSE() in drivers/remoteproc/qcom_q6v5.o
    see include/linux/module.h for more information
    ERROR: "qcom_q6v5_init" [drivers/remoteproc/qcom_q6v5_pil.ko] undefined!
    ERROR: "qcom_q6v5_wait_for_start" [drivers/remoteproc/qcom_q6v5_pil.ko] undefined!
    ERROR: "qcom_q6v5_prepare" [drivers/remoteproc/qcom_q6v5_pil.ko] undefined!
    ERROR: "qcom_q6v5_unprepare" [drivers/remoteproc/qcom_q6v5_pil.ko] undefined!
    ERROR: "qcom_q6v5_request_stop" [drivers/remoteproc/qcom_q6v5_pil.ko] undefined!
    ERROR: "qcom_q6v5_init" [drivers/remoteproc/qcom_adsp_pil.ko] undefined!
    ERROR: "qcom_q6v5_wait_for_start" [drivers/remoteproc/qcom_adsp_pil.ko] undefined!
    ERROR: "qcom_q6v5_prepare" [drivers/remoteproc/qcom_adsp_pil.ko] undefined!
    ERROR: "qcom_q6v5_unprepare" [drivers/remoteproc/qcom_adsp_pil.ko] undefined!
    ERROR: "qcom_q6v5_request_stop" [drivers/remoteproc/qcom_adsp_pil.ko] undefined!

    This exports the internal symbols as needed and adds the MODULE_LICENSE()
    and MODULE_DESCRIPTION() tags. I could not figure out the author, so I
    did not add a MODULE_AUTHOR() tag for now.

    Fixes: 3b415c8fb263 ("remoteproc: q6v5: Extract common resource handling")
    Signed-off-by: Arnd Bergmann
    Signed-off-by: Bjorn Andersson

    Arnd Bergmann
     

27 Jun, 2018

5 commits

  • On rare occasions a subdevice might need to prepare some hardware
    resources before a remote processor is booted, and clean up some
    state after it has been shut down.

    One such example is the IP Accelerator found in various Qualcomm
    platforms, which is accessed directly from both the modem remoteproc
    and the application subsystem and requires an intricate lockstep
    process when bringing the modem up and down.

    Tested-by: Fabien Dessenne
    Signed-off-by: Bjorn Andersson
    [elder@linaro.org: minor description and comment edits]
    Signed-off-by Alex Elder
    Signed-off-by: Bjorn Andersson

    Bjorn Andersson
     
  • Rename functions used when subdevices are started and stopped to
    reflect the new naming scheme.

    Tested-by: Fabien Dessenne
    Signed-off-by Alex Elder
    Signed-off-by: Bjorn Andersson

    Alex Elder
     
  • In preparation of adding the additional prepare and unprepare operations
    make the client responsible for filling out the function pointers of the
    rproc_subdev. This makes the arguments to rproc_add_subdev() more
    manageable, in particular when some of the functions are left out.

    Tested-by: Fabien Dessenne
    Signed-off-by: Bjorn Andersson
    [elder@linaro.org: added comment about assigning function pointers]
    Signed-off-by Alex Elder
    Signed-off-by: Bjorn Andersson

    Bjorn Andersson
     
  • Some subdevices, such as glink ssr only care about the stop operation,
    so make the operations optional to reduce client code.

    Tested-by: Fabien Dessenne
    Signed-off-by: Bjorn Andersson
    Signed-off-by Alex Elder
    Signed-off-by: Bjorn Andersson

    Bjorn Andersson
     
  • "start" and "stop" are more suitable names for how these two operations
    are used, and they fit better with the upcoming introduction of two
    additional operations in the struct.

    Tested-by: Fabien Dessenne
    Signed-off-by: Bjorn Andersson
    [elder@linaro.org: minor comment edits]
    Signed-off-by Alex Elder
    Signed-off-by: Bjorn Andersson

    Bjorn Andersson
     

19 Jun, 2018

4 commits


15 Jun, 2018

1 commit

  • With PHYS_ADDR_MAX there is now a type safe variant for all bits set.
    Make use of it.

    Patch created using a semantic patch as follows:

    //
    @@
    typedef phys_addr_t;
    @@
    -(phys_addr_t)ULLONG_MAX
    +PHYS_ADDR_MAX
    //

    Link: http://lkml.kernel.org/r/20180419214204.19322-1-stefan@agner.ch
    Signed-off-by: Stefan Agner
    Reviewed-by: Andrew Morton
    Acked-by: Ard Biesheuvel
    Acked-by: Catalin Marinas [arm64]
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Stefan Agner
     

30 May, 2018

3 commits


22 May, 2018

2 commits


10 May, 2018

4 commits


26 Apr, 2018

3 commits

  • Remove dependencies on HAS_DMA where a Kconfig symbol depends on another
    symbol that implies HAS_DMA, and, optionally, on "|| COMPILE_TEST".
    In most cases this other symbol is an architecture or platform specific
    symbol, or PCI.

    Generic symbols and drivers without platform dependencies keep their
    dependencies on HAS_DMA, to prevent compiling subsystems or drivers that
    cannot work anyway.

    This simplifies the dependencies, and allows to improve compile-testing.

    Signed-off-by: Geert Uytterhoeven
    Reviewed-by: Mark Brown
    Acked-by: Robin Murphy
    Acked-by: Bjorn Andersson
    Signed-off-by: Bjorn Andersson

    Geert Uytterhoeven
     
  • Add missing of_node_put()s at two places for device nodes returned by
    of_parse_phandle().

    Fixes: 051fb70fd4ea ("remoteproc: qcom: Driver for the self-authenticating
    Hexagon v5")
    Signed-off-by: Tobias Jordan
    Signed-off-by: Bjorn Andersson

    Tobias Jordan
     
  • Fix rproc_add_subdev parameter name and inverse the crashed logic.

    Fixes: 880f5b388252 ("remoteproc: Pass type of shutdown to subdev remove")
    Reviewed-by: Alex Elder
    Signed-off-by: Arnaud Pouliquen
    Signed-off-by: Bjorn Andersson

    Arnaud Pouliquen
     

18 Apr, 2018

1 commit


06 Apr, 2018

1 commit


28 Mar, 2018

1 commit

  • Access to the socket API and the root network namespace is only available
    when networking is enabled:

    ERROR: "kernel_sendmsg" [drivers/soc/qcom/qmi_helpers.ko] undefined!
    ERROR: "sock_release" [drivers/soc/qcom/qmi_helpers.ko] undefined!
    ERROR: "sock_create_kern" [drivers/soc/qcom/qmi_helpers.ko] undefined!
    ERROR: "kernel_getsockname" [drivers/soc/qcom/qmi_helpers.ko] undefined!
    ERROR: "init_net" [drivers/soc/qcom/qmi_helpers.ko] undefined!
    ERROR: "kernel_recvmsg" [drivers/soc/qcom/qmi_helpers.ko] undefined!

    Adding a dependency on CONFIG_NET lets us build it in all randconfig
    builds.

    Fixes: 9b8a11e82615 ("soc: qcom: Introduce QMI encoder/decoder")
    Acked-by: Andy Gross
    Signed-off-by: Arnd Bergmann
    Signed-off-by: Bjorn Andersson

    Arnd Bergmann
     

19 Mar, 2018

3 commits


13 Feb, 2018

3 commits

  • The sysmon client communicates either via a dedicated SMD/GLINK channel
    or via QMI encoded messages over IPCROUTER with remote processors in
    order to perform graceful shutdown and inform about other remote
    processors shutting down.

    Acked-By: Chris Lew
    Signed-off-by: Bjorn Andersson

    Bjorn Andersson
     
  • remoteproc instances can be stopped either by invoking shutdown or by an
    attempt to recover from a crash. For some subdev types it's expected to
    clean up gracefully during a shutdown, but are unable to do so during a
    crash - so pass this information to the subdev remove functions.

    Acked-By: Chris Lew
    Signed-off-by: Bjorn Andersson

    Bjorn Andersson
     
  • Register MDT segments with the remoteproc core dump functionality in
    order to include them in a core dump, in case of a recovery of the remote
    processor.

    Signed-off-by: Sarangdhar Joshi
    Signed-off-by: Bjorn Andersson

    Sarangdhar Joshi