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

Commit 1cbabf9c authored by Antti Palosaari's avatar Antti Palosaari Committed by Mauro Carvalho Chehab
Browse files

[media] af9035: remove one config parameter



We can use tuner ID instead of HW not supported flag.
Lesser code is better code.

Signed-off-by: default avatarAntti Palosaari <crope@iki.fi>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 2a79eefa
Loading
Loading
Loading
Loading
+2 −2
Original line number Original line Diff line number Diff line
@@ -615,7 +615,6 @@ static int af9035_read_mac_address(struct dvb_usb_device *d, u8 mac[6])
			state->af9033_config[i].spec_inv = 1;
			state->af9033_config[i].spec_inv = 1;
			break;
			break;
		default:
		default:
			state->hw_not_supported = true;
			warn("tuner ID=%02x not supported, please report!",
			warn("tuner ID=%02x not supported, please report!",
				tmp);
				tmp);
		};
		};
@@ -809,7 +808,8 @@ static int af9035_frontend_attach(struct dvb_usb_adapter *adap)
	struct state *state = adap->dev->priv;
	struct state *state = adap->dev->priv;
	int ret;
	int ret;


	if (state->hw_not_supported) {
	if (!state->af9033_config[adap->id].tuner) {
		/* unsupported tuner */
		ret = -ENODEV;
		ret = -ENODEV;
		goto err;
		goto err;
	}
	}
+0 −1
Original line number Original line Diff line number Diff line
@@ -54,7 +54,6 @@ struct usb_req {


struct state {
struct state {
	bool dual_mode;
	bool dual_mode;
	bool hw_not_supported;


	struct af9033_config af9033_config[2];
	struct af9033_config af9033_config[2];
};
};