diff options
author | Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> | 2018-12-03 15:08:59 +0530 |
---|---|---|
committer | Vernon Mauery <vernon.mauery@linux.intel.com> | 2018-12-11 14:29:30 +0000 |
commit | a45cb34ff6e6c778e2d2b86518afb8bc0a54d189 (patch) | |
tree | 605604911d40cc575c6be9fa927e6922de1e571c /user_channel/user_mgmt.hpp | |
parent | ae4b040bd08839efcbc08a78d4f6ce6d77e66050 (diff) | |
download | phosphor-host-ipmid-a45cb34ff6e6c778e2d2b86518afb8bc0a54d189.tar.gz phosphor-host-ipmid-a45cb34ff6e6c778e2d2b86518afb8bc0a54d189.zip |
Update const uint8_t& to const uint8_t
Update const uint8_t& to const uint8_t usage. Passing by reference
for small types are costly than passing it by value and hence the
change is done
Unit-Test
1. Performed build and verified regular user account creation
and RMCP+ login
Change-Id: Ic2dd76795749148f82564677dde2a5db08520454
Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com>
Diffstat (limited to 'user_channel/user_mgmt.hpp')
-rw-r--r-- | user_channel/user_mgmt.hpp | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/user_channel/user_mgmt.hpp b/user_channel/user_mgmt.hpp index 5755fa0..a54486f 100644 --- a/user_channel/user_mgmt.hpp +++ b/user_channel/user_mgmt.hpp @@ -92,7 +92,7 @@ class UserAccess * * @return true if valid, false otherwise */ - static bool isValidChannel(const uint8_t& chNum); + static bool isValidChannel(const uint8_t chNum); /** @brief determines valid userId * @@ -100,7 +100,7 @@ class UserAccess * * @return true if valid, false otherwise */ - static bool isValidUserId(const uint8_t& userId); + static bool isValidUserId(const uint8_t userId); /** @brief determines valid user privilege * @@ -108,7 +108,7 @@ class UserAccess * * @return true if valid, false otherwise */ - static bool isValidPrivilege(const uint8_t& priv); + static bool isValidPrivilege(const uint8_t priv); /** @brief determines sync index to be mapped with common-user-management * @@ -155,7 +155,7 @@ class UserAccess * * @return UserInfo for the specified user id */ - UserInfo* getUserInfo(const uint8_t& userId); + UserInfo* getUserInfo(const uint8_t userId); /** @brief sets user information * @@ -163,7 +163,7 @@ class UserAccess * @param[in] userInfo - user information * */ - void setUserInfo(const uint8_t& userId, UserInfo* userInfo); + void setUserInfo(const uint8_t userId, UserInfo* userInfo); /** @brief provides user name * @@ -172,7 +172,7 @@ class UserAccess * * @return IPMI_CC_OK for success, others for failure. */ - ipmi_ret_t getUserName(const uint8_t& userId, std::string& userName); + ipmi_ret_t getUserName(const uint8_t userId, std::string& userName); /** @brief to set user name * @@ -181,7 +181,7 @@ class UserAccess * * @return IPMI_CC_OK for success, others for failure. */ - ipmi_ret_t setUserName(const uint8_t& userId, const char* userNameInChar); + ipmi_ret_t setUserName(const uint8_t userId, const char* userNameInChar); /** @brief to set user enabled state * @@ -190,7 +190,7 @@ class UserAccess * * @return IPMI_CC_OK for success, others for failure. */ - ipmi_ret_t setUserEnabledState(const uint8_t& userId, + ipmi_ret_t setUserEnabledState(const uint8_t userId, const bool& enabledState); /** @brief to set user privilege and access details @@ -203,8 +203,7 @@ class UserAccess * * @return IPMI_CC_OK for success, others for failure. */ - ipmi_ret_t setUserPrivilegeAccess(const uint8_t& userId, - const uint8_t& chNum, + ipmi_ret_t setUserPrivilegeAccess(const uint8_t userId, const uint8_t chNum, const UserPrivAccess& privAccess, const bool& otherPrivUpdates); |