treewide: remove redundant IS_ERR() before error code check
[linux/fpc-iii.git] / drivers / media / usb / pvrusb2 / pvrusb2-wm8775.c
blob5f800f4a829c67b5b2729354dc2769731324f643
1 // SPDX-License-Identifier: GPL-2.0-only
2 /*
4 * Copyright (C) 2005 Mike Isely <isely@pobox.com>
5 * Copyright (C) 2004 Aurelien Alleaume <slts@free.fr>
6 */
8 /*
10 This source file is specifically designed to interface with the
11 wm8775.
15 #include "pvrusb2-wm8775.h"
18 #include "pvrusb2-hdw-internal.h"
19 #include "pvrusb2-debug.h"
20 #include <linux/videodev2.h>
21 #include <media/v4l2-common.h>
22 #include <linux/errno.h>
24 void pvr2_wm8775_subdev_update(struct pvr2_hdw *hdw, struct v4l2_subdev *sd)
26 if (hdw->input_dirty || hdw->force_dirty) {
27 u32 input;
29 switch (hdw->input_val) {
30 case PVR2_CVAL_INPUT_RADIO:
31 input = 1;
32 break;
33 default:
34 /* All other cases just use the second input */
35 input = 2;
36 break;
38 pvr2_trace(PVR2_TRACE_CHIPS, "subdev wm8775 set_input(val=%d route=0x%x)",
39 hdw->input_val, input);
41 sd->ops->audio->s_routing(sd, input, 0, 0);