wenquan2015 commented on PR #3782:
URL: https://github.com/apache/nuttx-apps/pull/3782#issuecomment-5747253837

   > Hi @wenquan1,
   > 
   > Following your request to test PR #3789 on physical hardware, we 
identified a regression when running on flat builds (`CONFIG_BUILD_FLAT=y`) 
without a filesystem mounted on `/tmp` (e.g. bare-metal microcontrollers like 
STM32): `ptpd -t <pid>` timed out with error 110 because the status file in 
`/tmp` could not be created or read.
   > 
   > To address this cleanly without breaking your improvements for 
Protected/Kernel modes, we updated this PR with a hybrid approach in commit 
`35073e5e0` (`netutils/ptpd: retain in-memory IPC for CONFIG_BUILD_FLAT in 
ptpd_status()`):
   > 
   > * On **`CONFIG_BUILD_FLAT`**: retains the original fast in-memory 
`sigqueue` + semaphore IPC directly in address space, removing the filesystem 
requirement for lightweight embedded boards.
   > * On **`!CONFIG_BUILD_FLAT`** (Protected / Kernel builds): retains your 
file-based IPC via `/tmp` to safely cross user/kernel address space boundaries.
   > 
   > We have validated this on real hardware (running NuttX flat build). Could 
you please take a look and share your review?
   > 
   > Thanks!
   
   Sorry I overlooked this scenario. If the target has a writable filesystem, 
we can set NETUTILS_PTPD_STATUSFILE to a suitable path and let ptpd write its 
status there directly. the hybrid patch have some comments to fix.
   Thanks!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to