/* Persists receiver context if there is a free place.  */
static int mdm_receiver_get(struct mdm_receiver_context *ctx)
/* Persists receiver context if there is a free place.  */
static int mdm_receiver_get(struct mdm_receiver_context *ctx)
{
	int i;
	for (i = 0; i < MAX_MDM_CTX; i++) {
		if (!contexts[i]) {
			contexts[i] = ctx;
			return 0;
		}
	}
	return -ENOMEM;
}