Skip to content
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

shell: Allocate proper amount of history slab memory #13048

Merged
merged 1 commit into from
Feb 6, 2019

Conversation

agross-oss
Copy link
Collaborator

This patch increases the amount of slab memory per item for the shell
history to match the maximum command input buffer size plus the
accounting information for the dnode list item.

Signed-off-by: Andy Gross [email protected]

@codecov-io
Copy link

codecov-io commented Feb 5, 2019

Codecov Report

Merging #13048 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master   #13048   +/-   ##
=======================================
  Coverage   48.63%   48.63%           
=======================================
  Files         313      313           
  Lines       46436    46436           
  Branches    10710    10710           
=======================================
  Hits        22585    22585           
  Misses      19395    19395           
  Partials     4456     4456
Impacted Files Coverage Δ
subsys/shell/shell_history.c 75.43% <ø> (ø) ⬆️
include/shell/shell_history.h 0% <ø> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d34c116...0d8a8aa. Read the comment docs.

@nordic-krch
Copy link
Contributor

i will improve history handling in the future in terms of ram used as current solution is not optimal but let's get that in so that goes to 1.14.

@agross-oss
Copy link
Collaborator Author

reduced number of buffers by 1 to offset memory cost of increasing the overall per buffer size.

@agross-oss
Copy link
Collaborator Author

Found a nice issue with k_mem_slab allowing for non-aligned block size. So added in ROUND_UP() to fix that.

This patch increases the amount of slab memory per item for the shell
history to match the maximum command input buffer size plus the
accounting information for the dnode list item.

Signed-off-by: Andy Gross <[email protected]>
@nashif nashif merged commit 1e968a1 into zephyrproject-rtos:master Feb 6, 2019
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.

7 participants