[PATCH 2/2] SysmoBTS: refactor code to simplify understanding

Holger Freyther holger at freyther.de
Fri Apr 22 13:35:23 UTC 2016


> On 21 Apr 2016, at 18:43, msuraev at sysmocom.de wrote:
> 
> From: Max <msuraev at sysmocom.de>

Hi Max,


> 
> Use bool type for boolean values.
> Move common code out of if.. else.

is this worth our time?



> -		timeout_secs = 30;
> 	} else {
> 		SuperFemto_Prim_t *sysp = msgb_sysprim(msg);
> 
> @@ -135,9 +134,10 @@ static int _l1if_req_compl(struct femtol1_hdl *fl1h, struct msgb *msg,
> 		wlc->is_sys_prim = 1;
> 		wlc->conf_prim_id = femtobts_sysprim_req2conf[sysp->id];
> 		wqueue = &fl1h->write_q[MQ_SYS_WRITE];
> -		timeout_secs = 30;
> 	}
> 
> +	timeout_secs = 30;

then make it const int timeout_secs = 30;





More information about the OpenBSC mailing list