summaryrefslogtreecommitdiff
path: root/fuzz
diff options
context:
space:
mode:
authorJack Rosenthal <jrosenth@chromium.org>2022-06-27 15:06:59 -0600
committerChromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com>2022-06-29 02:19:15 +0000
commitddfe5c1e469327498d4593636d1dc5472dd0ed32 (patch)
tree85bed5b945c7e1b7b493cdd0c70caf32a9b4039b /fuzz
parent658b879da45718b13c7ba3fdfb017f319ad4a064 (diff)
downloadchrome-ec-ddfe5c1e469327498d4593636d1dc5472dd0ed32.tar.gz
fuzz/pchg_fuzz.c: Format with clang-format
BUG=b:236386294 BRANCH=none TEST=none Change-Id: Iaf95eadbb1d8ed2b18166ef3be1a6f765c4bd4f9 Signed-off-by: Jack Rosenthal <jrosenth@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3730194 Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
Diffstat (limited to 'fuzz')
-rw-r--r--fuzz/pchg_fuzz.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/fuzz/pchg_fuzz.c b/fuzz/pchg_fuzz.c
index 97dbca74c4..eced90bb5e 100644
--- a/fuzz/pchg_fuzz.c
+++ b/fuzz/pchg_fuzz.c
@@ -40,15 +40,15 @@ static pthread_cond_t done_cond;
static pthread_mutex_t lock;
#define MAX_MESSAGES 8
-#define MAX_MESSAGE_SIZE (sizeof(struct ctn730_msg) \
- + member_size(struct ctn730_msg, length) * 256)
+#define MAX_MESSAGE_SIZE \
+ (sizeof(struct ctn730_msg) + \
+ member_size(struct ctn730_msg, length) * 256)
static uint8_t input[MAX_MESSAGE_SIZE * MAX_MESSAGES];
static uint8_t *head, *tail;
static bool data_available;
-int pchg_i2c_xfer(int port, uint16_t addr_flags,
- const uint8_t *out, int out_size,
- uint8_t *in, int in_size, int flags)
+int pchg_i2c_xfer(int port, uint16_t addr_flags, const uint8_t *out,
+ int out_size, uint8_t *in, int in_size, int flags)
{
if (port != I2C_PORT_WLC || addr_flags != CTN730_I2C_ADDR)
return EC_ERROR_INVAL;
@@ -92,7 +92,6 @@ void irq_task(int argc, char **argv)
pthread_cond_signal(&done_cond);
pthread_mutex_unlock(&lock);
}
-
}
void run_test(int argc, char **argv)