Replies: 5 comments 2 replies
-
@brgl Looks like your kernel commit 1f2bcb8 is what causes the additional delay (milliseconds vs. microseconds). Specifically, reverting desc_set_label() back resolves the issue for me. Context: openocd uses gpiod to bitbang swdio configurations over a pin. |
Beta Was this translation helpful? Give feedback.
-
This may be possible (SRCU write synchronization is known to be slower that spinlocks or mutexes) although running the libgpiod test-suite takes the same time between v6.8 and v6.9-rc5 (if anything, the latter is even slightly faster). My concern is that you're probably using the API wrong if you need to request/release GPIO lines in quick succession. Changing the direction without releasing the line has been possible for over a year with libgpiod v2. Could you consider switching to the new version? Please take a look at |
Beta Was this translation helpful? Give feedback.
-
FYI: there is ongoing work for openocd to switch to libgpiod v2.x, it would be great if you could test this latest branch: https://github.com/mhei/openocd/tree/linuxgpiodv2-emulate-v2-for-v1 |
Beta Was this translation helpful? Give feedback.
-
@brgl I'll try to those test suites on my hardware and see the #s. Can you confirm those test multicore systems? (If I pin the user worker thread to the same core as the kernel, problems go away). @mhei Oh, nice. I tested and it unfortunately exits out without error or completion. I don't want to turn the thread into an openocd ticket, but the program out put is below. I'll dig in more on Monday and possibly follow up through another channel.
|
Beta Was this translation helpful? Give feedback.
-
This was fixed with commit |
Beta Was this translation helpful? Give feedback.
-
A recent change in linux kernel from 6.8 to 6.9 makes releasing a gpio fd take a consequential amount of time (depending on what core your app vs. your kernel is using). I need to switch a pin's direction rapidly, which was traditionally done by releasing and requesting the line again - however this now taking way too long.
Following up on this stackoverflow post, there is hopefully another way to do this in newer kernel revisions. Can you provide any guidance on how to proceed?
Beta Was this translation helpful? Give feedback.
All reactions