Wind River Support Network


CGP8-381 : OpenHpi leaks file descriptors

Created: Feb 8, 2018    Updated: Mar 5, 2019
Resolved Date: Apr 12, 2018
Found In Version:
Fix Version:
Severity: Standard
Applicable for: Wind River Linux 8
Component/s: Userspace


Calling saHpiSessionOpen/saHpiSessionClose leaves a file descriptor open.

Steps to Reproduce

1) Create a simple CGP project with openhpi

configure --enable-addons=wr-cgp --with-layer=cgp --enable-board=intel-x86-64 --enable-kernel=cgl --enable-rootfs=glibc-cgl --with-package=openhpi --enable-reconfig --with-rcpl-version=0024

2) Include a test case, I attached it as a layer in order to not use the SDK (extract the attached tarball in the root of the project)

3) Add the openhpi-test package to the project

make lib32-openhpi-test.addpkg && make

4) Start the target and start openhpid service with systemctl. You will need to disable the first line before.


5) Run openhpi-test in the background

6) There are two ways to see the issue:

6.1) ls -l /proc/`pidof wrl8_openhpi_test`/fd can be used to monitor file descriptor being leaked.
6.2) strace the test program, close() 

Other Downloads

Live chat