Hi Kerogit, Alin, I have opened the Pull Request for Step 1 on GitHub on behalf of Kerogit: https://github.com/apache/nuttx/pull/20677
All 4 commits preserve Kerogit's original authorship and DCO sign-offs, rebased cleanly onto current master, and checked with nxstyle. As discussed, we will proceed step-by-step: once this PR is reviewed and merged, we can proceed with Step 2 (Zero Latency Interrupts). Best regards, Swatantra Yadav On Thu, 15 Oct 2026 at 03:15, <[email protected]> wrote: > Hello, > > thanks to everyone for the offers. First part of the series is ready in > the Git repository, branch is named avrdx_fixes_13.1. The PR description > is below. I'll be looking at Github and if any question arise, I will > answer them here. > > And just in case - since you mention splitting the patches into > individual PRs. If you mean breaking the branch into 4 separate > branches, I would advise against that. The features more or less depend > on each other (software interrupt emulation changes file added by the > zero latency interrupts, WS2812 uses both of these features etc.) so > trying to split them up is most likely going to end with git conflicts > and code that does not build. That's why I was planning to merge this in > step-by-step fashion. > > The filled PR template: > > ============================ > > AVR DA/DB: fix for build failure and other smaller fixes > > ## Summary > > This patch series fixes build failure for AVR DA/DB family and adds some > other smaller fixes. > > The build failure was caused by patch series that added LIBC_ATOMIC_IRQ > Kconfig option during 13.1 development. Commit 4ca2256a9bee selects this > option by default for AVR chips but not for the DA/DB family, causing a > build failure (atomic functions are missing.) The first patch of this > series simply adds missing "select LIBC_ATOMIC_IRQ" for this family as > well. > > Other than that, version 13.1 added a performance regression which > manifested as dropped bytes in USART peripheral during receive (with > heavy round-robin preemptive scheduling load.) The regression was > bisected to commit b32712d0a2 that fixes some bugs (which were affecting > AVR DA/DB default build as well) but apparently adds more time-consuming > work to context switch with interrupts disabled. The patch for this > simply documents this possibility in the USART driver description. > > The remaining patches fix unused variable warning, make (very unlikely) > board initialization error more visible and reorder manipulation with > stack pointer during context restore to do it in the way (presumably) > intended by the chip manufacturer. > > ## Impact > > After the patch is applied, it is again possible to build the code. > Other than that, there is no impact on existing code/users. > > The stack pointer reordering change is done in file shared with other > AVR families - #ifdef blocks are used to cause no change for them > > ## Testing > > I confirm that changes are verified on local setup and work as > intended: > * Build Host: Linux, AMD, GCC-AVR 14.2 > * Target: AVR (AVR128DA28), breadxavr:nsh > > Testing logs before change: > > ``` > $ tools/configure.sh -l breadxavr:nsh > $ make -j16 > ... > avr-ld: .../nuttx.git/staging/libsched.a(sem_destroy.o): in function > `.L3': > sem_destroy.c:(.text.nxsem_destroy+0x46): undefined reference to > `__atomic_load_4' > ... > ``` > > Testing logs after change: > > ``` > $ tools/configure.sh -l breadxavr:nsh > $ make -j16 > Register: nsh > Register: sh > LD: nuttx > Memory region Used Size Region Size %age Used > flash: 56377 B 128 KB 43.01% > sram: 780 B 16 KB 4.76% > eeprom: 0 B 512 B 0.00% > rodata: 606 B 4 KB 14.79% > CP: nuttx.hex > CP: nuttx.asm > ``` > > To verify that the stack pointer change did not affect other AVR > families, mega1284p-xplained:nsh was built before and after the change. > The resulting binary was identical (with the exception of version > string.) > > Header and source files were checked by checkpatch with no issues found, > spelling checked with aspell. > > ## PR verification Self-Check > > * [x] This PR introduces only one functional change. > * [x] I have updated all required description fields above. > * [x] My PR adheres to Contributing > [Guidelines](https://github.com/apache/nuttx/blob/master/CONTRIBUTING.md) > and > [Documentation]( > https://nuttx.apache.org/docs/latest/contributing/index.html) > (git commit title and message, coding standard, etc). > * [ ] My PR is still work in progress (not ready for review). > * [x] My PR is ready for review and can be safely merged into a > codebase. > > ============================ > > On 2026-10-14 18:20, Abhishek Mishra wrote: > > Hi, > > > > I'd be happy to help split the patches into individual PRs and work on > > getting them merged. Please let me know how you'd like to coordinate. > > > > Best regards, > > Abhishek > > > > On Wed, Oct 14, 2026 at 9:09 PM Alin Jerpelea <[email protected]> > > wrote: > > > >> please prepare the first patches and I will handle them > >> > >> Best regards > >> Alin J > >> > >> On Wed, 14 Oct 2026, 16:37 Alin Jerpelea, <[email protected]> wrote: > >> > >> > Hi, > >> > > >> > I can lend a hand tomorrow > >> > > >> > Thanks for your message > >> > > >> > Best regards > >> > Alin > >> > > >> > On Wed, 14 Oct 2026, 11:18 Felipe Moura Oliveira, < > [email protected]> > >> > wrote: > >> > > >> >> Hello, > >> >> > >> >> I am away from my desk for the next few days. If no one offers to > help > >> by > >> >> this weekend, I will reach out to you so I can help you with this. > >> >> > >> >> Regards, > >> >> > >> >> > >> >> *--Felipe Moura de Oliveira* > >> >> Linkedin <https://www.linkedin.com/in/felipe-oliveira-75a651a0> > >> >> > >> >> On Wed, 14 Oct 2026 at 10:48 <[email protected]> wrote: > >> >> > >> >> > Hello, > >> >> > > >> >> > I would like to ask someone to help me merge some patches for the > AVR > >> >> > architecture, DA/DB family. I have a series ready with some fixes > and > >> >> > some new features. Same as before, I don't have a Github account > so I > >> am > >> >> > looking for someone who could open pull requests > >> >> > > >> >> > The series as a whole is available in my "nuttx.git" repository at > >> >> > git.kerogit.eu accessible through HTTP/S. The relevant branch is > >> named > >> >> > avrdx_ws2812_upstream . > >> >> > > >> >> > In its current form, the branch is not suitable for merging - it > would > >> >> > be more than one feature per one PR which is against the > contributing > >> >> > rules. My plan is, if someone decides to help, to split the series > >> into > >> >> > steps and merge these steps one by one. After one step is merged, I > >> >> > would rebase the remainder on current master branch and provide > next > >> >> > step. I also plan to prepare text to be filled in the PR form > >> >> > (essentialy doing as much as possible to make the job easier for > the > >> >> > person who will interact with Github.) > >> >> > > >> >> > There are four features: > >> >> > > >> >> > 1. fixes - build failure introduced between 13.0 and 13.1, > documenting > >> >> > performance regression between these versions and some minor stuff > >> >> > 2. zero latency interrupt support - > >> >> > > >> >> > > >> >> > >> > https://nuttx.apache.org/docs/latest/guides/concurrency/zerolatencyinterrupts.html > >> >> > 3. software interrupt emulation > >> >> > 4. lower half for WS2812 driver > >> >> > > >> >> > Thanks > >> >> > > >> >> > >> > > >> >
