diff options
| author | Stefan Kerkmann <karlk90@pm.me> | 2022-01-27 06:13:27 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-01-26 21:13:27 -0800 |
| commit | be59e8af2b8efcee2933f3b9e40129bc1d8f9d1c (patch) | |
| tree | 7572b4881859eb27027f011aa183a7d4f5331019 | |
| parent | ed8ab3e32c31bf45d266997444210fe30d21df77 (diff) | |
Deprecate split transactions status field (#16023)
| -rw-r--r-- | drivers/serial.h | 19 | ||||
| -rw-r--r-- | platforms/avr/drivers/serial.c | 39 | ||||
| -rw-r--r-- | platforms/chibios/drivers/serial.c | 19 | ||||
| -rw-r--r-- | platforms/chibios/drivers/serial_usart.c | 32 | ||||
| -rw-r--r-- | quantum/split_common/transactions.c | 7 | ||||
| -rw-r--r-- | quantum/split_common/transactions.h | 1 | ||||
| -rw-r--r-- | quantum/split_common/transport.c | 2 |
7 files changed, 28 insertions, 91 deletions
diff --git a/drivers/serial.h b/drivers/serial.h index d9c2a69e96..0cfdbd9959 100644 --- a/drivers/serial.h +++ b/drivers/serial.h | |||
| @@ -26,21 +26,4 @@ void soft_serial_initiator_init(void); | |||
| 26 | // target is interrupt accept side | 26 | // target is interrupt accept side |
| 27 | void soft_serial_target_init(void); | 27 | void soft_serial_target_init(void); |
| 28 | 28 | ||
| 29 | // initiator result | 29 | bool soft_serial_transaction(int sstd_index); |
| 30 | #define TRANSACTION_END 0 | ||
| 31 | #define TRANSACTION_NO_RESPONSE 0x1 | ||
| 32 | #define TRANSACTION_DATA_ERROR 0x2 | ||
| 33 | #define TRANSACTION_TYPE_ERROR 0x4 | ||
| 34 | int soft_serial_transaction(int sstd_index); | ||
| 35 | |||
| 36 | // target status | ||
| 37 | // *SSTD_t.status has | ||
| 38 | // initiator: | ||
| 39 | // TRANSACTION_END | ||
| 40 | // or TRANSACTION_NO_RESPONSE | ||
| 41 | // or TRANSACTION_DATA_ERROR | ||
| 42 | // target: | ||
| 43 | // TRANSACTION_DATA_ERROR | ||
| 44 | // or TRANSACTION_ACCEPTED | ||
| 45 | #define TRANSACTION_ACCEPTED 0x8 | ||
| 46 | int soft_serial_get_and_clean_status(int sstd_index); | ||
diff --git a/platforms/avr/drivers/serial.c b/platforms/avr/drivers/serial.c index ab0b52afd1..62908e5875 100644 --- a/platforms/avr/drivers/serial.c +++ b/platforms/avr/drivers/serial.c | |||
| @@ -409,13 +409,7 @@ ISR(SERIAL_PIN_INTERRUPT) { | |||
| 409 | 409 | ||
| 410 | // target recive phase | 410 | // target recive phase |
| 411 | if (trans->initiator2target_buffer_size > 0) { | 411 | if (trans->initiator2target_buffer_size > 0) { |
| 412 | if (serial_recive_packet((uint8_t *)split_trans_initiator2target_buffer(trans), trans->initiator2target_buffer_size)) { | 412 | serial_recive_packet((uint8_t *)split_trans_initiator2target_buffer(trans), trans->initiator2target_buffer_size); |
| 413 | *trans->status = TRANSACTION_ACCEPTED; | ||
| 414 | } else { | ||
| 415 | *trans->status = TRANSACTION_DATA_ERROR; | ||
| 416 | } | ||
| 417 | } else { | ||
| 418 | *trans->status = TRANSACTION_ACCEPTED; | ||
| 419 | } | 413 | } |
| 420 | 414 | ||
| 421 | sync_recv(); // weit initiator output to high | 415 | sync_recv(); // weit initiator output to high |
| @@ -424,19 +418,13 @@ ISR(SERIAL_PIN_INTERRUPT) { | |||
| 424 | ///////// | 418 | ///////// |
| 425 | // start transaction by initiator | 419 | // start transaction by initiator |
| 426 | // | 420 | // |
| 427 | // int soft_serial_transaction(int sstd_index) | 421 | // bool soft_serial_transaction(int sstd_index) |
| 428 | // | 422 | // |
| 429 | // Returns: | ||
| 430 | // TRANSACTION_END | ||
| 431 | // TRANSACTION_NO_RESPONSE | ||
| 432 | // TRANSACTION_DATA_ERROR | ||
| 433 | // this code is very time dependent, so we need to disable interrupts | 423 | // this code is very time dependent, so we need to disable interrupts |
| 434 | int soft_serial_transaction(int sstd_index) { | 424 | bool soft_serial_transaction(int sstd_index) { |
| 435 | if (sstd_index > NUM_TOTAL_TRANSACTIONS) return TRANSACTION_TYPE_ERROR; | 425 | if (sstd_index > NUM_TOTAL_TRANSACTIONS) return false; |
| 436 | split_transaction_desc_t *trans = &split_transaction_table[sstd_index]; | 426 | split_transaction_desc_t *trans = &split_transaction_table[sstd_index]; |
| 437 | 427 | ||
| 438 | if (!trans->status) return TRANSACTION_TYPE_ERROR; // not registered | ||
| 439 | |||
| 440 | cli(); | 428 | cli(); |
| 441 | 429 | ||
| 442 | // signal to the target that we want to start a transaction | 430 | // signal to the target that we want to start a transaction |
| @@ -463,9 +451,8 @@ int soft_serial_transaction(int sstd_index) { | |||
| 463 | // slave failed to pull the line low, assume not present | 451 | // slave failed to pull the line low, assume not present |
| 464 | serial_output(); | 452 | serial_output(); |
| 465 | serial_high(); | 453 | serial_high(); |
| 466 | *trans->status = TRANSACTION_NO_RESPONSE; | ||
| 467 | sei(); | 454 | sei(); |
| 468 | return TRANSACTION_NO_RESPONSE; | 455 | return false; |
| 469 | } | 456 | } |
| 470 | _delay_sub_us(SLAVE_INT_ACK_WIDTH_UNIT); | 457 | _delay_sub_us(SLAVE_INT_ACK_WIDTH_UNIT); |
| 471 | } | 458 | } |
| @@ -476,9 +463,8 @@ int soft_serial_transaction(int sstd_index) { | |||
| 476 | if (!serial_recive_packet((uint8_t *)split_trans_target2initiator_buffer(trans), trans->target2initiator_buffer_size)) { | 463 | if (!serial_recive_packet((uint8_t *)split_trans_target2initiator_buffer(trans), trans->target2initiator_buffer_size)) { |
| 477 | serial_output(); | 464 | serial_output(); |
| 478 | serial_high(); | 465 | serial_high(); |
| 479 | *trans->status = TRANSACTION_DATA_ERROR; | ||
| 480 | sei(); | 466 | sei(); |
| 481 | return TRANSACTION_DATA_ERROR; | 467 | return false; |
| 482 | } | 468 | } |
| 483 | } | 469 | } |
| 484 | 470 | ||
| @@ -493,19 +479,8 @@ int soft_serial_transaction(int sstd_index) { | |||
| 493 | // always, release the line when not in use | 479 | // always, release the line when not in use |
| 494 | sync_send(); | 480 | sync_send(); |
| 495 | 481 | ||
| 496 | *trans->status = TRANSACTION_END; | ||
| 497 | sei(); | ||
| 498 | return TRANSACTION_END; | ||
| 499 | } | ||
| 500 | |||
| 501 | int soft_serial_get_and_clean_status(int sstd_index) { | ||
| 502 | split_transaction_desc_t *trans = &split_transaction_table[sstd_index]; | ||
| 503 | cli(); | ||
| 504 | int retval = *trans->status; | ||
| 505 | *trans->status = 0; | ||
| 506 | ; | ||
| 507 | sei(); | 482 | sei(); |
| 508 | return retval; | 483 | return true; |
| 509 | } | 484 | } |
| 510 | #endif | 485 | #endif |
| 511 | 486 | ||
diff --git a/platforms/chibios/drivers/serial.c b/platforms/chibios/drivers/serial.c index ef6f0aa8d5..17d0b32be8 100644 --- a/platforms/chibios/drivers/serial.c +++ b/platforms/chibios/drivers/serial.c | |||
| @@ -179,8 +179,6 @@ void interrupt_handler(void *arg) { | |||
| 179 | // wait for the sync to finish sending | 179 | // wait for the sync to finish sending |
| 180 | serial_delay(); | 180 | serial_delay(); |
| 181 | 181 | ||
| 182 | *trans->status = (checksum_computed == checksum_received) ? TRANSACTION_ACCEPTED : TRANSACTION_DATA_ERROR; | ||
| 183 | |||
| 184 | // end transaction | 182 | // end transaction |
| 185 | serial_input(); | 183 | serial_input(); |
| 186 | 184 | ||
| @@ -193,17 +191,12 @@ void interrupt_handler(void *arg) { | |||
| 193 | ///////// | 191 | ///////// |
| 194 | // start transaction by initiator | 192 | // start transaction by initiator |
| 195 | // | 193 | // |
| 196 | // int soft_serial_transaction(int sstd_index) | 194 | // bool soft_serial_transaction(int sstd_index) |
| 197 | // | 195 | // |
| 198 | // Returns: | ||
| 199 | // TRANSACTION_END | ||
| 200 | // TRANSACTION_NO_RESPONSE | ||
| 201 | // TRANSACTION_DATA_ERROR | ||
| 202 | // this code is very time dependent, so we need to disable interrupts | 196 | // this code is very time dependent, so we need to disable interrupts |
| 203 | int soft_serial_transaction(int sstd_index) { | 197 | bool soft_serial_transaction(int sstd_index) { |
| 204 | if (sstd_index > NUM_TOTAL_TRANSACTIONS) return TRANSACTION_TYPE_ERROR; | 198 | if (sstd_index > NUM_TOTAL_TRANSACTIONS) return false; |
| 205 | split_transaction_desc_t *trans = &split_transaction_table[sstd_index]; | 199 | split_transaction_desc_t *trans = &split_transaction_table[sstd_index]; |
| 206 | if (!trans->status) return TRANSACTION_TYPE_ERROR; // not registered | ||
| 207 | 200 | ||
| 208 | // TODO: remove extra delay between transactions | 201 | // TODO: remove extra delay between transactions |
| 209 | serial_delay(); | 202 | serial_delay(); |
| @@ -226,7 +219,7 @@ int soft_serial_transaction(int sstd_index) { | |||
| 226 | // slave failed to pull the line low, assume not present | 219 | // slave failed to pull the line low, assume not present |
| 227 | dprintf("serial::NO_RESPONSE\n"); | 220 | dprintf("serial::NO_RESPONSE\n"); |
| 228 | chSysUnlock(); | 221 | chSysUnlock(); |
| 229 | return TRANSACTION_NO_RESPONSE; | 222 | return false; |
| 230 | } | 223 | } |
| 231 | 224 | ||
| 232 | // if the slave is present syncronize with it | 225 | // if the slave is present syncronize with it |
| @@ -266,7 +259,7 @@ int soft_serial_transaction(int sstd_index) { | |||
| 266 | serial_high(); | 259 | serial_high(); |
| 267 | 260 | ||
| 268 | chSysUnlock(); | 261 | chSysUnlock(); |
| 269 | return TRANSACTION_DATA_ERROR; | 262 | return false; |
| 270 | } | 263 | } |
| 271 | 264 | ||
| 272 | // always, release the line when not in use | 265 | // always, release the line when not in use |
| @@ -274,5 +267,5 @@ int soft_serial_transaction(int sstd_index) { | |||
| 274 | serial_output(); | 267 | serial_output(); |
| 275 | 268 | ||
| 276 | chSysUnlock(); | 269 | chSysUnlock(); |
| 277 | return TRANSACTION_END; | 270 | return true; |
| 278 | } | 271 | } |
diff --git a/platforms/chibios/drivers/serial_usart.c b/platforms/chibios/drivers/serial_usart.c index 124e4be685..42c476a374 100644 --- a/platforms/chibios/drivers/serial_usart.c +++ b/platforms/chibios/drivers/serial_usart.c | |||
| @@ -36,7 +36,7 @@ static SerialDriver* serial_driver = &SERIAL_USART_DRIVER; | |||
| 36 | static inline bool react_to_transactions(void); | 36 | static inline bool react_to_transactions(void); |
| 37 | static inline bool __attribute__((nonnull)) receive(uint8_t* destination, const size_t size); | 37 | static inline bool __attribute__((nonnull)) receive(uint8_t* destination, const size_t size); |
| 38 | static inline bool __attribute__((nonnull)) send(const uint8_t* source, const size_t size); | 38 | static inline bool __attribute__((nonnull)) send(const uint8_t* source, const size_t size); |
| 39 | static inline int initiate_transaction(uint8_t sstd_index); | 39 | static inline bool initiate_transaction(uint8_t sstd_index); |
| 40 | static inline void usart_clear(void); | 40 | static inline void usart_clear(void); |
| 41 | 41 | ||
| 42 | /** | 42 | /** |
| @@ -206,14 +206,12 @@ static inline bool react_to_transactions(void) { | |||
| 206 | to signal that the slave is ready to receive possible transaction buffers */ | 206 | to signal that the slave is ready to receive possible transaction buffers */ |
| 207 | sstd_index ^= HANDSHAKE_MAGIC; | 207 | sstd_index ^= HANDSHAKE_MAGIC; |
| 208 | if (!send(&sstd_index, sizeof(sstd_index))) { | 208 | if (!send(&sstd_index, sizeof(sstd_index))) { |
| 209 | *trans->status = TRANSACTION_DATA_ERROR; | ||
| 210 | return false; | 209 | return false; |
| 211 | } | 210 | } |
| 212 | 211 | ||
| 213 | /* Receive transaction buffer from the master. If this transaction requires it.*/ | 212 | /* Receive transaction buffer from the master. If this transaction requires it.*/ |
| 214 | if (trans->initiator2target_buffer_size) { | 213 | if (trans->initiator2target_buffer_size) { |
| 215 | if (!receive(split_trans_initiator2target_buffer(trans), trans->initiator2target_buffer_size)) { | 214 | if (!receive(split_trans_initiator2target_buffer(trans), trans->initiator2target_buffer_size)) { |
| 216 | *trans->status = TRANSACTION_DATA_ERROR; | ||
| 217 | return false; | 215 | return false; |
| 218 | } | 216 | } |
| 219 | } | 217 | } |
| @@ -226,12 +224,10 @@ static inline bool react_to_transactions(void) { | |||
| 226 | /* Send transaction buffer to the master. If this transaction requires it. */ | 224 | /* Send transaction buffer to the master. If this transaction requires it. */ |
| 227 | if (trans->target2initiator_buffer_size) { | 225 | if (trans->target2initiator_buffer_size) { |
| 228 | if (!send(split_trans_target2initiator_buffer(trans), trans->target2initiator_buffer_size)) { | 226 | if (!send(split_trans_target2initiator_buffer(trans), trans->target2initiator_buffer_size)) { |
| 229 | *trans->status = TRANSACTION_DATA_ERROR; | ||
| 230 | return false; | 227 | return false; |
| 231 | } | 228 | } |
| 232 | } | 229 | } |
| 233 | 230 | ||
| 234 | *trans->status = TRANSACTION_ACCEPTED; | ||
| 235 | return true; | 231 | return true; |
| 236 | } | 232 | } |
| 237 | 233 | ||
| @@ -252,11 +248,9 @@ void soft_serial_initiator_init(void) { | |||
| 252 | * @brief Start transaction from the master half to the slave half. | 248 | * @brief Start transaction from the master half to the slave half. |
| 253 | * | 249 | * |
| 254 | * @param index Transaction Table index of the transaction to start. | 250 | * @param index Transaction Table index of the transaction to start. |
| 255 | * @return int TRANSACTION_NO_RESPONSE in case of Timeout. | 251 | * @return bool Indicates success of transaction. |
| 256 | * TRANSACTION_TYPE_ERROR in case of invalid transaction index. | ||
| 257 | * TRANSACTION_END in case of success. | ||
| 258 | */ | 252 | */ |
| 259 | int soft_serial_transaction(int index) { | 253 | bool soft_serial_transaction(int index) { |
| 260 | /* Clear the receive queue, to start with a clean slate. | 254 | /* Clear the receive queue, to start with a clean slate. |
| 261 | * Parts of failed transactions or spurious bytes could still be in it. */ | 255 | * Parts of failed transactions or spurious bytes could still be in it. */ |
| 262 | usart_clear(); | 256 | usart_clear(); |
| @@ -266,25 +260,19 @@ int soft_serial_transaction(int index) { | |||
| 266 | /** | 260 | /** |
| 267 | * @brief Initiate transaction to slave half. | 261 | * @brief Initiate transaction to slave half. |
| 268 | */ | 262 | */ |
| 269 | static inline int initiate_transaction(uint8_t sstd_index) { | 263 | static inline bool initiate_transaction(uint8_t sstd_index) { |
| 270 | /* Sanity check that we are actually starting a valid transaction. */ | 264 | /* Sanity check that we are actually starting a valid transaction. */ |
| 271 | if (sstd_index >= NUM_TOTAL_TRANSACTIONS) { | 265 | if (sstd_index >= NUM_TOTAL_TRANSACTIONS) { |
| 272 | dprintln("USART: Illegal transaction Id."); | 266 | dprintln("USART: Illegal transaction Id."); |
| 273 | return TRANSACTION_TYPE_ERROR; | 267 | return false; |
| 274 | } | 268 | } |
| 275 | 269 | ||
| 276 | split_transaction_desc_t* trans = &split_transaction_table[sstd_index]; | 270 | split_transaction_desc_t* trans = &split_transaction_table[sstd_index]; |
| 277 | 271 | ||
| 278 | /* Transaction is not registered. Abort. */ | ||
| 279 | if (!trans->status) { | ||
| 280 | dprintln("USART: Transaction not registered."); | ||
| 281 | return TRANSACTION_TYPE_ERROR; | ||
| 282 | } | ||
| 283 | |||
| 284 | /* Send transaction table index to the slave, which doubles as basic handshake token. */ | 272 | /* Send transaction table index to the slave, which doubles as basic handshake token. */ |
| 285 | if (!send(&sstd_index, sizeof(sstd_index))) { | 273 | if (!send(&sstd_index, sizeof(sstd_index))) { |
| 286 | dprintln("USART: Send Handshake failed."); | 274 | dprintln("USART: Send Handshake failed."); |
| 287 | return TRANSACTION_TYPE_ERROR; | 275 | return false; |
| 288 | } | 276 | } |
| 289 | 277 | ||
| 290 | uint8_t sstd_index_shake = 0xFF; | 278 | uint8_t sstd_index_shake = 0xFF; |
| @@ -295,14 +283,14 @@ static inline int initiate_transaction(uint8_t sstd_index) { | |||
| 295 | */ | 283 | */ |
| 296 | if (!receive(&sstd_index_shake, sizeof(sstd_index_shake)) || (sstd_index_shake != (sstd_index ^ HANDSHAKE_MAGIC))) { | 284 | if (!receive(&sstd_index_shake, sizeof(sstd_index_shake)) || (sstd_index_shake != (sstd_index ^ HANDSHAKE_MAGIC))) { |
| 297 | dprintln("USART: Handshake failed."); | 285 | dprintln("USART: Handshake failed."); |
| 298 | return TRANSACTION_NO_RESPONSE; | 286 | return false; |
| 299 | } | 287 | } |
| 300 | 288 | ||
| 301 | /* Send transaction buffer to the slave. If this transaction requires it. */ | 289 | /* Send transaction buffer to the slave. If this transaction requires it. */ |
| 302 | if (trans->initiator2target_buffer_size) { | 290 | if (trans->initiator2target_buffer_size) { |
| 303 | if (!send(split_trans_initiator2target_buffer(trans), trans->initiator2target_buffer_size)) { | 291 | if (!send(split_trans_initiator2target_buffer(trans), trans->initiator2target_buffer_size)) { |
| 304 | dprintln("USART: Send failed."); | 292 | dprintln("USART: Send failed."); |
| 305 | return TRANSACTION_NO_RESPONSE; | 293 | return false; |
| 306 | } | 294 | } |
| 307 | } | 295 | } |
| 308 | 296 | ||
| @@ -310,9 +298,9 @@ static inline int initiate_transaction(uint8_t sstd_index) { | |||
| 310 | if (trans->target2initiator_buffer_size) { | 298 | if (trans->target2initiator_buffer_size) { |
| 311 | if (!receive(split_trans_target2initiator_buffer(trans), trans->target2initiator_buffer_size)) { | 299 | if (!receive(split_trans_target2initiator_buffer(trans), trans->target2initiator_buffer_size)) { |
| 312 | dprintln("USART: Receive failed."); | 300 | dprintln("USART: Receive failed."); |
| 313 | return TRANSACTION_NO_RESPONSE; | 301 | return false; |
| 314 | } | 302 | } |
| 315 | } | 303 | } |
| 316 | 304 | ||
| 317 | return TRANSACTION_END; | 305 | return true; |
| 318 | } | 306 | } |
diff --git a/quantum/split_common/transactions.c b/quantum/split_common/transactions.c index d9e8fd1f6b..4b059a2b8a 100644 --- a/quantum/split_common/transactions.c +++ b/quantum/split_common/transactions.c | |||
| @@ -35,11 +35,11 @@ | |||
| 35 | #define sizeof_member(type, member) sizeof(((type *)NULL)->member) | 35 | #define sizeof_member(type, member) sizeof(((type *)NULL)->member) |
| 36 | 36 | ||
| 37 | #define trans_initiator2target_initializer_cb(member, cb) \ | 37 | #define trans_initiator2target_initializer_cb(member, cb) \ |
| 38 | { &dummy, sizeof_member(split_shared_memory_t, member), offsetof(split_shared_memory_t, member), 0, 0, cb } | 38 | { sizeof_member(split_shared_memory_t, member), offsetof(split_shared_memory_t, member), 0, 0, cb } |
| 39 | #define trans_initiator2target_initializer(member) trans_initiator2target_initializer_cb(member, NULL) | 39 | #define trans_initiator2target_initializer(member) trans_initiator2target_initializer_cb(member, NULL) |
| 40 | 40 | ||
| 41 | #define trans_target2initiator_initializer_cb(member, cb) \ | 41 | #define trans_target2initiator_initializer_cb(member, cb) \ |
| 42 | { &dummy, 0, 0, sizeof_member(split_shared_memory_t, member), offsetof(split_shared_memory_t, member), cb } | 42 | { 0, 0, sizeof_member(split_shared_memory_t, member), offsetof(split_shared_memory_t, member), cb } |
| 43 | #define trans_target2initiator_initializer(member) trans_target2initiator_initializer_cb(member, NULL) | 43 | #define trans_target2initiator_initializer(member) trans_target2initiator_initializer_cb(member, NULL) |
| 44 | 44 | ||
| 45 | #define transport_write(id, data, length) transport_execute_transaction(id, data, length, NULL, 0) | 45 | #define transport_write(id, data, length) transport_execute_transaction(id, data, length, NULL, 0) |
| @@ -658,10 +658,9 @@ static void pointing_handlers_slave(matrix_row_t master_matrix[], matrix_row_t s | |||
| 658 | 658 | ||
| 659 | //////////////////////////////////////////////////// | 659 | //////////////////////////////////////////////////// |
| 660 | 660 | ||
| 661 | uint8_t dummy; | ||
| 662 | split_transaction_desc_t split_transaction_table[NUM_TOTAL_TRANSACTIONS] = { | 661 | split_transaction_desc_t split_transaction_table[NUM_TOTAL_TRANSACTIONS] = { |
| 663 | // Set defaults | 662 | // Set defaults |
| 664 | [0 ...(NUM_TOTAL_TRANSACTIONS - 1)] = {NULL, 0, 0, 0, 0, 0}, | 663 | [0 ...(NUM_TOTAL_TRANSACTIONS - 1)] = {0, 0, 0, 0, 0}, |
| 665 | 664 | ||
| 666 | #ifdef USE_I2C | 665 | #ifdef USE_I2C |
| 667 | [I2C_EXECUTE_CALLBACK] = trans_initiator2target_initializer(transaction_id), | 666 | [I2C_EXECUTE_CALLBACK] = trans_initiator2target_initializer(transaction_id), |
diff --git a/quantum/split_common/transactions.h b/quantum/split_common/transactions.h index 53610d6f8e..e38ec79ce9 100644 --- a/quantum/split_common/transactions.h +++ b/quantum/split_common/transactions.h | |||
| @@ -27,7 +27,6 @@ typedef void (*slave_callback_t)(uint8_t initiator2target_buffer_size, const voi | |||
| 27 | 27 | ||
| 28 | // Split transaction Descriptor | 28 | // Split transaction Descriptor |
| 29 | typedef struct _split_transaction_desc_t { | 29 | typedef struct _split_transaction_desc_t { |
| 30 | uint8_t * status; | ||
| 31 | uint8_t initiator2target_buffer_size; | 30 | uint8_t initiator2target_buffer_size; |
| 32 | uint16_t initiator2target_offset; | 31 | uint16_t initiator2target_offset; |
| 33 | uint8_t target2initiator_buffer_size; | 32 | uint8_t target2initiator_buffer_size; |
diff --git a/quantum/split_common/transport.c b/quantum/split_common/transport.c index bcc0261417..060ba8a927 100644 --- a/quantum/split_common/transport.c +++ b/quantum/split_common/transport.c | |||
| @@ -99,7 +99,7 @@ bool transport_execute_transaction(int8_t id, const void *initiator2target_buf, | |||
| 99 | memcpy(split_trans_initiator2target_buffer(trans), initiator2target_buf, len); | 99 | memcpy(split_trans_initiator2target_buffer(trans), initiator2target_buf, len); |
| 100 | } | 100 | } |
| 101 | 101 | ||
| 102 | if (soft_serial_transaction(id) != TRANSACTION_END) { | 102 | if (!soft_serial_transaction(id)) { |
| 103 | return false; | 103 | return false; |
| 104 | } | 104 | } |
| 105 | 105 | ||
