Smarter MIN, MAX, ABS macros
Use macros that explicitly avoid double-evaluation and can be used for any datatype, replacing `min`, `max`, `abs`, `fabs`, `labs`, and `FABS`. Co-Authored-By: ejtagle <ejtagle@hotmail.com>
This commit is contained in:
@@ -1904,7 +1904,7 @@ static void udd_ep_in_sent(udd_ep_id_t ep)
|
||||
ptr_src = &ptr_job->buf[ptr_job->buf_cnt];
|
||||
nb_remain = ptr_job->buf_size - ptr_job->buf_cnt;
|
||||
// Fill a bank even if no data (ZLP)
|
||||
nb_data = min(nb_remain, pkt_size);
|
||||
nb_data = MIN(nb_remain, pkt_size);
|
||||
// Modify job information
|
||||
ptr_job->buf_cnt += nb_data;
|
||||
ptr_job->buf_load = nb_data;
|
||||
|
||||
Reference in New Issue
Block a user