Change in osmo-ccid-firmware[master]: prevent uart interrupts before having proper structs

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

laforge gerrit-no-reply at lists.osmocom.org
Thu Nov 28 15:23:42 UTC 2019


laforge has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ccid-firmware/+/16271 )

Change subject: prevent uart interrupts before having proper structs
......................................................................

prevent uart interrupts before having proper structs

Change-Id: I9cf7ff883721211ae11821339505d2e3b2a7961e
---
M sysmoOCTSIM/main.c
1 file changed, 3 insertions(+), 0 deletions(-)

Approvals:
  Jenkins Builder: Verified
  laforge: Looks good to me, approved



diff --git a/sysmoOCTSIM/main.c b/sysmoOCTSIM/main.c
index 0f2409a..7ddca92 100644
--- a/sysmoOCTSIM/main.c
+++ b/sysmoOCTSIM/main.c
@@ -470,6 +470,8 @@
 
 	LOGP(DUSB, LOGL_ERROR, "foobar usb\n");
 
+	//prevent spurious interrupts before our driver structs are ready
+	CRITICAL_SECTION_ENTER()
 	ccid_instance_init(&g_ci, &c_ops, &iso_fsm_slot_ops, &usb_fs_descs.ccid.class,
 			   data_rates, clock_freqs, "", 0);
 
@@ -480,6 +482,7 @@
 		llist_add_tail_at(&msg->list, &g_ccid_s.free_q);
 	}
 	submit_next_out();
+	CRITICAL_SECTION_LEAVE()
 
 //	command_print_prompt();
 	while (true) { // main loop

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-ccid-firmware/+/16271
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ccid-firmware
Gerrit-Branch: master
Gerrit-Change-Id: I9cf7ff883721211ae11821339505d2e3b2a7961e
Gerrit-Change-Number: 16271
Gerrit-PatchSet: 4
Gerrit-Owner: Hoernchen <ewild at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge at osmocom.org>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20191128/e74668da/attachment.htm>


More information about the gerrit-log mailing list