Skip to content

Commit

Permalink
staging/easycap: replace underscored types with regular once
Browse files Browse the repository at this point in the history
the underscored types should be used in user space headers only

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Tomas Winkler authored and Greg Kroah-Hartman committed Feb 4, 2011
1 parent 1a4cb0f commit 055e3a3
Show file tree
Hide file tree
Showing 7 changed files with 170 additions and 170 deletions.
46 changes: 23 additions & 23 deletions drivers/staging/easycap/easycap.h
Original file line number Diff line number Diff line change
Expand Up @@ -259,8 +259,8 @@ struct data_buffer {
struct list_head list_head;
void *pgo;
void *pto;
__u16 kount;
__u16 input;
u16 kount;
u16 input;
};
/*---------------------------------------------------------------------------*/
struct data_urb {
Expand All @@ -271,11 +271,11 @@ struct data_urb {
};
/*---------------------------------------------------------------------------*/
struct easycap_standard {
__u16 mask;
u16 mask;
struct v4l2_standard v4l2_standard;
};
struct easycap_format {
__u16 mask;
u16 mask;
char name[128];
struct v4l2_format v4l2_format;
};
Expand Down Expand Up @@ -323,7 +323,7 @@ struct easycap {

#define UPSAMPLE
#ifdef UPSAMPLE
__s16 oldaudio;
s16 oldaudio;
#endif /*UPSAMPLE*/

int ilk;
Expand Down Expand Up @@ -388,12 +388,12 @@ struct easycap {
struct list_head urb_video_head;
struct list_head *purb_video_head;

__u8 cache[8];
__u8 *pcache;
u8 cache[8];
u8 *pcache;
int video_mt;
int audio_mt;
long long audio_bytes;
__u32 isequence;
u32 isequence;

int vma_many;
/*---------------------------------------------------------------------------*/
Expand All @@ -418,7 +418,7 @@ struct easycap {
* IMAGE PROPERTIES
*/
/*---------------------------------------------------------------------------*/
__u32 pixelformat;
u32 pixelformat;
int width;
int height;
int bytesperpixel;
Expand Down Expand Up @@ -516,12 +516,12 @@ int submit_video_urbs(struct easycap *);
int kill_video_urbs(struct easycap *);
int field2frame(struct easycap *);
int redaub(struct easycap *, void *, void *,
int, int, __u8, __u8, bool);
int, int, u8, u8, bool);
void easycap_testcard(struct easycap *, int);
int fillin_formats(void);
int newinput(struct easycap *, int);
int adjust_standard(struct easycap *, v4l2_std_id);
int adjust_format(struct easycap *, __u32, __u32, __u32,
int adjust_format(struct easycap *, u32, u32, u32,
int, bool);
int adjust_brightness(struct easycap *, int);
int adjust_contrast(struct easycap *, int);
Expand Down Expand Up @@ -551,9 +551,9 @@ int audio_setup(struct easycap *);
*/
/*---------------------------------------------------------------------------*/
int audio_gainget(struct usb_device *);
int audio_gainset(struct usb_device *, __s8);
int audio_gainset(struct usb_device *, s8);

int set_interface(struct usb_device *, __u16);
int set_interface(struct usb_device *, u16);
int wakeup_device(struct usb_device *);
int confirm_resolution(struct usb_device *);
int confirm_stream(struct usb_device *);
Expand All @@ -568,20 +568,20 @@ int merit_saa(struct usb_device *);
int check_vt(struct usb_device *);
int select_input(struct usb_device *, int, int);
int set_resolution(struct usb_device *,
__u16, __u16, __u16, __u16);
u16, u16, u16, u16);

int read_saa(struct usb_device *, __u16);
int read_stk(struct usb_device *, __u32);
int write_saa(struct usb_device *, __u16, __u16);
int read_saa(struct usb_device *, u16);
int read_stk(struct usb_device *, u32);
int write_saa(struct usb_device *, u16, u16);
int wait_i2c(struct usb_device *);
int write_000(struct usb_device *, __u16, __u16);
int write_000(struct usb_device *, u16, u16);
int start_100(struct usb_device *);
int stop_100(struct usb_device *);
int write_300(struct usb_device *);
int read_vt(struct usb_device *, __u16);
int write_vt(struct usb_device *, __u16, __u16);
int regset(struct usb_device *, __u16, __u16);
int regget(struct usb_device *, __u16, void *);
int read_vt(struct usb_device *, u16);
int write_vt(struct usb_device *, u16, u16);
int regset(struct usb_device *, u16, u16);
int regget(struct usb_device *, u16, void *);
int isdongle(struct easycap *);
/*---------------------------------------------------------------------------*/
struct signed_div_result {
Expand All @@ -597,7 +597,7 @@ struct signed_div_result {
/*---------------------------------------------------------------------------*/
#define GET(X, Y, Z) do { \
int rc; \
*(Z) = (__u16)0; \
*(Z) = (u16)0; \
rc = regget(X, Y, Z); \
if (0 > rc) { \
JOT(8, ":-(%i\n", __LINE__); return(rc); \
Expand Down
40 changes: 20 additions & 20 deletions drivers/staging/easycap/easycap_ioctl.c
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
int adjust_standard(struct easycap *peasycap, v4l2_std_id std_id)
{
struct easycap_standard const *peasycap_standard;
__u16 reg, set;
u16 reg, set;
int ir, rc, need, k;
unsigned int itwas, isnow;
bool resubmit;
Expand Down Expand Up @@ -340,14 +340,14 @@ return 0;
*/
/*--------------------------------------------------------------------------*/
int adjust_format(struct easycap *peasycap,
__u32 width, __u32 height, __u32 pixelformat, int field, bool try)
u32 width, u32 height, u32 pixelformat, int field, bool try)
{
struct easycap_format *peasycap_format, *peasycap_best_format;
__u16 mask;
u16 mask;
struct usb_device *p;
int miss, multiplier, best, k;
char bf[5], fo[32], *pc;
__u32 uc;
u32 uc;
bool resubmit;

if (NULL == peasycap) {
Expand Down Expand Up @@ -855,7 +855,7 @@ return -ENOENT;
/*****************************************************************************/
int adjust_volume(struct easycap *peasycap, int value)
{
__s8 mood;
s8 mood;
int i1;

if (NULL == peasycap) {
Expand Down Expand Up @@ -883,7 +883,7 @@ while (0xFFFFFFFF != easycap_control[i1].id) {
peasycap->volume = value;
mood = (16 > peasycap->volume) ? 16 :
((31 < peasycap->volume) ? 31 :
(__s8) peasycap->volume);
(s8) peasycap->volume);
if (!audio_gainset(peasycap->pusb_device, mood)) {
SAM("adjusting volume to 0x%02X\n", mood);
return 0;
Expand Down Expand Up @@ -1093,7 +1093,7 @@ case VIDIOC_QUERYCAP: {
/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
case VIDIOC_ENUMINPUT: {
struct v4l2_input v4l2_input;
__u32 index;
u32 index;

JOM(8, "VIDIOC_ENUMINPUT\n");

Expand Down Expand Up @@ -1195,12 +1195,12 @@ case VIDIOC_ENUMINPUT: {
}
/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
case VIDIOC_G_INPUT: {
__u32 index;
u32 index;

JOM(8, "VIDIOC_G_INPUT\n");
index = (__u32)peasycap->input;
index = (u32)peasycap->input;
JOM(8, "user is told: %i\n", index);
if (0 != copy_to_user((void __user *)arg, &index, sizeof(__u32))) {
if (0 != copy_to_user((void __user *)arg, &index, sizeof(u32))) {
mutex_unlock(&easycapdc60_dongle[kd].mutex_video);
return -EFAULT;
}
Expand All @@ -1209,12 +1209,12 @@ case VIDIOC_G_INPUT: {
/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
case VIDIOC_S_INPUT:
{
__u32 index;
u32 index;
int rc;

JOM(8, "VIDIOC_S_INPUT\n");

if (0 != copy_from_user(&index, (void __user *)arg, sizeof(__u32))) {
if (0 != copy_from_user(&index, (void __user *)arg, sizeof(u32))) {
mutex_unlock(&easycapdc60_dongle[kd].mutex_video);
return -EFAULT;
}
Expand Down Expand Up @@ -1465,7 +1465,7 @@ case VIDIOC_S_EXT_CTRLS: {
}
/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
case VIDIOC_ENUM_FMT: {
__u32 index;
u32 index;
struct v4l2_fmtdesc v4l2_fmtdesc;

JOM(8, "VIDIOC_ENUM_FMT\n");
Expand Down Expand Up @@ -1545,7 +1545,7 @@ case VIDIOC_ENUM_FMT: {
*/
/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
case VIDIOC_ENUM_FRAMESIZES: {
__u32 index;
u32 index;
struct v4l2_frmsizeenum v4l2_frmsizeenum;

JOM(8, "VIDIOC_ENUM_FRAMESIZES\n");
Expand All @@ -1558,7 +1558,7 @@ case VIDIOC_ENUM_FRAMESIZES: {

index = v4l2_frmsizeenum.index;

v4l2_frmsizeenum.type = (__u32) V4L2_FRMSIZE_TYPE_DISCRETE;
v4l2_frmsizeenum.type = (u32) V4L2_FRMSIZE_TYPE_DISCRETE;

if (true == peasycap->ntsc) {
switch (index) {
Expand Down Expand Up @@ -1681,7 +1681,7 @@ case VIDIOC_ENUM_FRAMESIZES: {
*/
/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
case VIDIOC_ENUM_FRAMEINTERVALS: {
__u32 index;
u32 index;
int denominator;
struct v4l2_frmivalenum v4l2_frmivalenum;

Expand All @@ -1704,7 +1704,7 @@ case VIDIOC_ENUM_FRAMEINTERVALS: {

index = v4l2_frmivalenum.index;

v4l2_frmivalenum.type = (__u32) V4L2_FRMIVAL_TYPE_DISCRETE;
v4l2_frmivalenum.type = (u32) V4L2_FRMIVAL_TYPE_DISCRETE;

switch (index) {
case 0: {
Expand Down Expand Up @@ -1904,7 +1904,7 @@ case VIDIOC_QUERYSTD: {
case VIDIOC_ENUMSTD: {
int last0 = -1, last1 = -1, last2 = -1, last3 = -1;
struct v4l2_standard v4l2_standard;
__u32 index;
u32 index;
struct easycap_standard const *peasycap_standard;

JOM(8, "VIDIOC_ENUMSTD\n");
Expand Down Expand Up @@ -2054,7 +2054,7 @@ case VIDIOC_REQBUFS: {
}
/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
case VIDIOC_QUERYBUF: {
__u32 index;
u32 index;
struct v4l2_buffer v4l2_buffer;

JOM(8, "VIDIOC_QUERYBUF\n");
Expand Down Expand Up @@ -2167,7 +2167,7 @@ case VIDIOC_DQBUF:
int i, j;
struct v4l2_buffer v4l2_buffer;
int rcdq;
__u16 input;
u16 input;

JOM(8, "VIDIOC_DQBUF\n");

Expand Down
Loading

0 comments on commit 055e3a3

Please sign in to comment.