Skip to content

Conversation

@stefpopa
Copy link
Contributor

@stefpopa stefpopa commented Jun 4, 2019

This PR adds support for ADF4372 and the output stage mute feature.
Common Clock Framework provider will follow in a different PR

@stefpopa stefpopa requested a review from a team June 4, 2019 12:07
@commodo
Copy link
Contributor

commodo commented Jun 4, 2019

one minor comment;
rest looks good

@stefpopa stefpopa force-pushed the master-adf4372_support branch from 3bf18fe to 561c095 Compare June 4, 2019 14:10
The st->spi element is NULL but used in the code. This patch fixes this
issue.

Signed-off-by: Stefan Popa <[email protected]>
@stefpopa stefpopa force-pushed the master-adf4372_support branch from 561c095 to 410e892 Compare June 4, 2019 14:13
@stefpopa
Copy link
Contributor Author

stefpopa commented Jun 4, 2019

Changes in v2:

  • added a new commit which deals with the NULL pointer bug
  • re-used adf4371_chan() for adf4372 channels

stefpopa added 4 commits June 4, 2019 17:30
The definition of RFAUX8 channel was accidentally duplicated as part of
adf4372_chan[] table.

Signed-off-by: Stefan Popa <[email protected]>
The ADF4372 is part of the same family with ADF4371, the main difference
is that it has only 3 channels instead of 4, as the frequency quadrupler
is missing. As a result, the ADF4372 allows frequencies from 62.5 MHz to
16 GHz to be generated.

Datasheet:
Link: https://www.analog.com/media/en/technical-documentation/data-sheets/adf4372.pdf

Signed-off-by: Stefan Popa <[email protected]>
Document support for ADF4372 SPI Wideband Synthesizer.

Signed-off-by: Stefan Popa <[email protected]>
Another feature of the ADF4371/ADF4372 is that the supply current to the
RF8P and RF8N output stage can shut down until the ADF4371 achieves lock
as measured by the digital lock detect circuitry. The mute to lock
detect bit (MUTE_LD) in REG25 enables this function.

Signed-off-by: Stefan Popa <[email protected]>
@stefpopa stefpopa force-pushed the master-adf4372_support branch from 410e892 to f1ec9b2 Compare June 4, 2019 14:35
@stefpopa
Copy link
Contributor Author

stefpopa commented Jun 4, 2019

Changes in v3:

  • Channel RF8AUX was accidentally duplicated. Added a new commit which fixes this issue

@commodo commodo merged commit 8d323cd into master Jun 5, 2019
@commodo commodo deleted the master-adf4372_support branch June 5, 2019 07:28
github-actions bot pushed a commit that referenced this pull request Aug 5, 2025
Use BPF_TRAMP_F_INDIRECT flag to detect struct ops and emit proper
prologue and epilogue for this case.

With this patch, all of the struct_ops related testcases (except
struct_ops_multi_pages) passed on LoongArch.

The testcase struct_ops_multi_pages failed is because the actual
image_pages_cnt is 40 which is bigger than MAX_TRAMP_IMAGE_PAGES.

Before:

  $ sudo ./test_progs -t struct_ops -d struct_ops_multi_pages
  ...
  WATCHDOG: test case struct_ops_module/struct_ops_load executes for 10 seconds...

After:

  $ sudo ./test_progs -t struct_ops -d struct_ops_multi_pages
  ...
  #15      bad_struct_ops:OK
  ...
  #399     struct_ops_autocreate:OK
  ...
  #400     struct_ops_kptr_return:OK
  ...
  #401     struct_ops_maybe_null:OK
  ...
  #402     struct_ops_module:OK
  ...
  #404     struct_ops_no_cfi:OK
  ...
  #405     struct_ops_private_stack:SKIP
  ...
  #406     struct_ops_refcounted:OK
  Summary: 8/25 PASSED, 3 SKIPPED, 0 FAILED

Signed-off-by: Tiezhu Yang <[email protected]>
Signed-off-by: Huacai Chen <[email protected]>
github-actions bot pushed a commit that referenced this pull request Aug 7, 2025
Use BPF_TRAMP_F_INDIRECT flag to detect struct ops and emit proper
prologue and epilogue for this case.

With this patch, all of the struct_ops related testcases (except
struct_ops_multi_pages) passed on LoongArch.

The testcase struct_ops_multi_pages failed is because the actual
image_pages_cnt is 40 which is bigger than MAX_TRAMP_IMAGE_PAGES.

Before:

  $ sudo ./test_progs -t struct_ops -d struct_ops_multi_pages
  ...
  WATCHDOG: test case struct_ops_module/struct_ops_load executes for 10 seconds...

After:

  $ sudo ./test_progs -t struct_ops -d struct_ops_multi_pages
  ...
  #15      bad_struct_ops:OK
  ...
  #399     struct_ops_autocreate:OK
  ...
  #400     struct_ops_kptr_return:OK
  ...
  #401     struct_ops_maybe_null:OK
  ...
  #402     struct_ops_module:OK
  ...
  #404     struct_ops_no_cfi:OK
  ...
  #405     struct_ops_private_stack:SKIP
  ...
  #406     struct_ops_refcounted:OK
  Summary: 8/25 PASSED, 3 SKIPPED, 0 FAILED

Signed-off-by: Tiezhu Yang <[email protected]>
Signed-off-by: Huacai Chen <[email protected]>
github-actions bot pushed a commit that referenced this pull request Oct 25, 2025
If of_genpd_add_provider_onecell() fails during probe, the previously
created generic power domains are not removed, leading to a memory leak
and potential kernel crash later in genpd_debug_add().

Add proper error handling to unwind the initialized domains before
returning from probe to ensure all resources are correctly released on
failure.

Example crash trace observed without this fix:

  | Unable to handle kernel paging request at virtual address fffffffffffffc70
  | CPU: 1 UID: 0 PID: 1 Comm: swapper/0 Not tainted 6.18.0-rc1 #405 PREEMPT
  | Hardware name: ARM LTD ARM Juno Development Platform/ARM Juno Development Platform
  | pstate: 00000005 (nzcv daif -PAN -UAO -TCO -DIT -SSBS BTYPE=--)
  | pc : genpd_debug_add+0x2c/0x160
  | lr : genpd_debug_init+0x74/0x98
  | Call trace:
  |  genpd_debug_add+0x2c/0x160 (P)
  |  genpd_debug_init+0x74/0x98
  |  do_one_initcall+0xd0/0x2d8
  |  do_initcall_level+0xa0/0x140
  |  do_initcalls+0x60/0xa8
  |  do_basic_setup+0x28/0x40
  |  kernel_init_freeable+0xe8/0x170
  |  kernel_init+0x2c/0x140
  |  ret_from_fork+0x10/0x20

Fixes: 898216c ("firmware: arm_scmi: add device power domain support using genpd")
Signed-off-by: Sudeep Holla <[email protected]>
Reviewed-by: Peng Fan <[email protected]>
Cc: [email protected]
Signed-off-by: Ulf Hansson <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants