Skip to content

Kinetis EMAC: Make number of buffers configurable #7141

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 11, 2018

Conversation

kjbracey
Copy link
Contributor

@kjbracey kjbracey commented Jun 6, 2018

Description

16 RX buffers and 8 TX buffers is probably excessive. Nanostack version of driver ( https://github.com/ARMmbed/sal-nanostack-driver-k64f-eth ) successfully used 4+4, and data pump should be broadly equivalent.

This means that switching K64F devices from Nanostack to EMAC for 5.9 increases base heap usage by 18K - observed in Nanostack border router builds.

Add a config option to make it possible for border router and others to lower the number of buffers.

Defer consideration of lowering the default to later - leaving it as 16+8 for now.

Pull request type

[X] Fix
[ ] Refactor
[ ] New target
[ ] Feature
[ ] Breaking change

@kjbracey
Copy link
Contributor Author

kjbracey commented Jun 6, 2018

FAO @mmahadevan108

@0xc0170 0xc0170 requested a review from a team June 6, 2018 10:22
@kjbracey kjbracey force-pushed the kinetis-mem-conf branch from a4c32f6 to eea7a98 Compare June 6, 2018 10:29
kjbracey added 2 commits June 6, 2018 13:30
16 RX buffers and 8 TX buffers is probably excessive. Nanostack
version of driver successfully used 4+4, and data pump should be
broadly equivalent.

This means that switching K64F devices from Nanostack to EMAC increases
base heap usage by 18K - observed in Nanostack border router builds.

Add a config option to make it possible to lower the number of buffers.
Defer consideration of lowering the default to later.
TX pointer array was using RX ring length in its declaration.
Wasted memory if RX ring > TX ring, as is the default, but would
be broken if RX ring < TX ring.
@kjbracey kjbracey force-pushed the kinetis-mem-conf branch from eea7a98 to a8e8775 Compare June 6, 2018 10:34
Copy link
Contributor

@mmahadevan108 mmahadevan108 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, looks good.

@kjbracey
Copy link
Contributor Author

kjbracey commented Jun 7, 2018

/morph build

@mbed-ci
Copy link

mbed-ci commented Jun 7, 2018

Build : SUCCESS

Build number : 2262
Build artifacts/logs : http://mbed-os.s3-website-eu-west-1.amazonaws.com/?prefix=builds/7141/

Triggering tests

/morph test
/morph uvisor-test
/morph export-build
/morph mbed2-build

@mbed-ci
Copy link

mbed-ci commented Jun 7, 2018

@cmonr
Copy link
Contributor

cmonr commented Jun 7, 2018

Halting CI builds until RC3 PRs are completed. Will resume after.

@0xc0170
Copy link
Contributor

0xc0170 commented Jun 8, 2018

/morph test
/morph export-build
/morph mbed2-build

@mbed-ci
Copy link

mbed-ci commented Jun 8, 2018

@mbed-ci
Copy link

mbed-ci commented Jun 8, 2018

@cmonr cmonr merged commit 2ac81de into ARMmbed:master Jun 11, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants