Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8e8a5ac7 authored by Antti Palosaari's avatar Antti Palosaari Committed by Mauro Carvalho Chehab
Browse files

[media] af9035: add log writing if unsupported Xtal freq is given



Supports currently only 12 MHz Xtals. It is better to print log
and not to attach frontend in that case.

Signed-off-by: default avatarAntti Palosaari <crope@iki.fi>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent e898ef62
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -667,6 +667,13 @@ struct dvb_frontend *af9033_attach(const struct af9033_config *config,
	state->i2c = i2c;
	memcpy(&state->cfg, config, sizeof(struct af9033_config));

	if (state->cfg.clock != 12000000) {
		printk(KERN_INFO "af9033: unsupported clock=%d, only " \
				"12000000 Hz is supported currently\n",
				state->cfg.clock);
		goto err;
	}

	/* firmware version */
	ret = af9033_rd_regs(state, 0x0083e9, &buf[0], 4);
	if (ret < 0)