drivers: gpio_dw: Remove contradictory if statement evaluation

This fixes an always false evaluation of the gpio I/O direction

This issue was reported by Coverity

Coverity-CID: 151978

Change-Id: I93ec3319a3f18d564c961a5cbd9dcc9c60efbeb7
Signed-off-by: Sergio Rodriguez <sergio.sf.rodriguez@intel.com>
This commit is contained in:
Sergio Rodriguez 2016-11-17 16:19:14 -08:00 committed by Anas Nashif
parent cd63c74bbd
commit 6b04e0669a

View file

@ -230,8 +230,7 @@ static inline void dw_port_config(struct device *port, int flags)
static inline int gpio_dw_config(struct device *port, int access_op,
uint32_t pin, int flags)
{
if (((flags & GPIO_INT) && (flags & GPIO_DIR_OUT)) ||
((flags & GPIO_DIR_IN) && (flags & GPIO_DIR_OUT))) {
if ((flags & GPIO_INT) && (flags & GPIO_DIR_OUT)) {
return -1;
}