aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ps3
diff options
context:
space:
mode:
authorValentin Ilie <valentin.ilie@gmail.com>2012-04-17 07:16:01 -0400
committerGeoff Levand <geoff@infradead.org>2012-04-24 21:18:01 -0400
commitf02777b4c0047e75b0b6db9a67aa49d29ae57965 (patch)
tree5c1ef26c3bd8f3df938d49017f39641339d088c6 /drivers/ps3
parent02ec92b3f312b7201928dc6d3225ed51635211b4 (diff)
drivers/ps3: Fix checkpatch warnings in ps3av.c
Signed-off-by: Valentin Ilie <valentin.ilie@gmail.com> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Geoff Levand <geoff@infradead.org>
Diffstat (limited to 'drivers/ps3')
-rw-r--r--drivers/ps3/ps3av.c24
1 files changed, 9 insertions, 15 deletions
diff --git a/drivers/ps3/ps3av.c b/drivers/ps3/ps3av.c
index a409fa050a1a..93d0a8b7718a 100644
--- a/drivers/ps3/ps3av.c
+++ b/drivers/ps3/ps3av.c
@@ -338,7 +338,7 @@ int ps3av_do_pkt(u32 cid, u16 send_len, size_t usr_buf_size,
338 mutex_unlock(&ps3av->mutex); 338 mutex_unlock(&ps3av->mutex);
339 return 0; 339 return 0;
340 340
341 err: 341err:
342 mutex_unlock(&ps3av->mutex); 342 mutex_unlock(&ps3av->mutex);
343 printk(KERN_ERR "%s: failed cid:%x res:%d\n", __func__, cid, res); 343 printk(KERN_ERR "%s: failed cid:%x res:%d\n", __func__, cid, res);
344 return res; 344 return res;
@@ -477,7 +477,6 @@ int ps3av_set_audio_mode(u32 ch, u32 fs, u32 word_bits, u32 format, u32 source)
477 477
478 return 0; 478 return 0;
479} 479}
480
481EXPORT_SYMBOL_GPL(ps3av_set_audio_mode); 480EXPORT_SYMBOL_GPL(ps3av_set_audio_mode);
482 481
483static int ps3av_set_videomode(void) 482static int ps3av_set_videomode(void)
@@ -501,7 +500,7 @@ static void ps3av_set_videomode_packet(u32 id)
501 500
502 video_mode = &video_mode_table[id & PS3AV_MODE_MASK]; 501 video_mode = &video_mode_table[id & PS3AV_MODE_MASK];
503 502
504 avb_param.num_of_video_pkt = PS3AV_AVB_NUM_VIDEO; /* num of head */ 503 avb_param.num_of_video_pkt = PS3AV_AVB_NUM_VIDEO; /* num of head */
505 avb_param.num_of_audio_pkt = 0; 504 avb_param.num_of_audio_pkt = 0;
506 avb_param.num_of_av_video_pkt = ps3av->av_hw_conf.num_of_hdmi + 505 avb_param.num_of_av_video_pkt = ps3av->av_hw_conf.num_of_hdmi +
507 ps3av->av_hw_conf.num_of_avmulti; 506 ps3av->av_hw_conf.num_of_avmulti;
@@ -521,7 +520,7 @@ static void ps3av_set_videomode_packet(u32 id)
521#ifndef PS3AV_HDMI_YUV 520#ifndef PS3AV_HDMI_YUV
522 if (ps3av->av_port[i] == PS3AV_CMD_AVPORT_HDMI_0 || 521 if (ps3av->av_port[i] == PS3AV_CMD_AVPORT_HDMI_0 ||
523 ps3av->av_port[i] == PS3AV_CMD_AVPORT_HDMI_1) 522 ps3av->av_port[i] == PS3AV_CMD_AVPORT_HDMI_1)
524 av_video_cs = RGB8; /* use RGB for HDMI */ 523 av_video_cs = RGB8; /* use RGB for HDMI */
525#endif 524#endif
526 len += ps3av_cmd_set_av_video_cs(&avb_param.buf[len], 525 len += ps3av_cmd_set_av_video_cs(&avb_param.buf[len],
527 ps3av->av_port[i], 526 ps3av->av_port[i],
@@ -590,8 +589,8 @@ static void ps3avd(struct work_struct *work)
590#define SHIFT_VESA 8 589#define SHIFT_VESA 8
591 590
592static const struct { 591static const struct {
593 unsigned mask : 19; 592 unsigned mask:19;
594 unsigned id : 4; 593 unsigned id:4;
595} ps3av_preferred_modes[] = { 594} ps3av_preferred_modes[] = {
596 { PS3AV_RESBIT_WUXGA << SHIFT_VESA, PS3AV_MODE_WUXGA }, 595 { PS3AV_RESBIT_WUXGA << SHIFT_VESA, PS3AV_MODE_WUXGA },
597 { PS3AV_RESBIT_1920x1080P << SHIFT_60, PS3AV_MODE_1080P60 }, 596 { PS3AV_RESBIT_1920x1080P << SHIFT_60, PS3AV_MODE_1080P60 },
@@ -667,7 +666,8 @@ static enum ps3av_mode_num ps3av_hdmi_get_id(struct ps3av_info_monitor *info)
667 return id; 666 return id;
668} 667}
669 668
670static void ps3av_monitor_info_dump(const struct ps3av_pkt_av_get_monitor_info *monitor_info) 669static void ps3av_monitor_info_dump(
670 const struct ps3av_pkt_av_get_monitor_info *monitor_info)
671{ 671{
672 const struct ps3av_info_monitor *info = &monitor_info->info; 672 const struct ps3av_info_monitor *info = &monitor_info->info;
673 const struct ps3av_info_audio *audio = info->audio; 673 const struct ps3av_info_audio *audio = info->audio;
@@ -717,8 +717,8 @@ static void ps3av_monitor_info_dump(const struct ps3av_pkt_av_get_monitor_info *
717 717
718 /* audio block */ 718 /* audio block */
719 for (i = 0; i < info->num_of_audio_block; i++) { 719 for (i = 0; i < info->num_of_audio_block; i++) {
720 pr_debug("audio[%d] type: %02x max_ch: %02x fs: %02x sbit: " 720 pr_debug(
721 "%02x\n", 721 "audio[%d] type: %02x max_ch: %02x fs: %02x sbit: %02x\n",
722 i, audio->type, audio->max_num_of_ch, audio->fs, 722 i, audio->type, audio->max_num_of_ch, audio->fs,
723 audio->sbit); 723 audio->sbit);
724 audio++; 724 audio++;
@@ -870,21 +870,18 @@ int ps3av_set_video_mode(int id)
870 870
871 return 0; 871 return 0;
872} 872}
873
874EXPORT_SYMBOL_GPL(ps3av_set_video_mode); 873EXPORT_SYMBOL_GPL(ps3av_set_video_mode);
875 874
876int ps3av_get_auto_mode(void) 875int ps3av_get_auto_mode(void)
877{ 876{
878 return ps3av_auto_videomode(&ps3av->av_hw_conf); 877 return ps3av_auto_videomode(&ps3av->av_hw_conf);
879} 878}
880
881EXPORT_SYMBOL_GPL(ps3av_get_auto_mode); 879EXPORT_SYMBOL_GPL(ps3av_get_auto_mode);
882 880
883int ps3av_get_mode(void) 881int ps3av_get_mode(void)
884{ 882{
885 return ps3av ? ps3av->ps3av_mode : 0; 883 return ps3av ? ps3av->ps3av_mode : 0;
886} 884}
887
888EXPORT_SYMBOL_GPL(ps3av_get_mode); 885EXPORT_SYMBOL_GPL(ps3av_get_mode);
889 886
890/* get resolution by video_mode */ 887/* get resolution by video_mode */
@@ -902,7 +899,6 @@ int ps3av_video_mode2res(u32 id, u32 *xres, u32 *yres)
902 *yres = video_mode_table[id].y; 899 *yres = video_mode_table[id].y;
903 return 0; 900 return 0;
904} 901}
905
906EXPORT_SYMBOL_GPL(ps3av_video_mode2res); 902EXPORT_SYMBOL_GPL(ps3av_video_mode2res);
907 903
908/* mute */ 904/* mute */
@@ -911,7 +907,6 @@ int ps3av_video_mute(int mute)
911 return ps3av_set_av_video_mute(mute ? PS3AV_CMD_MUTE_ON 907 return ps3av_set_av_video_mute(mute ? PS3AV_CMD_MUTE_ON
912 : PS3AV_CMD_MUTE_OFF); 908 : PS3AV_CMD_MUTE_OFF);
913} 909}
914
915EXPORT_SYMBOL_GPL(ps3av_video_mute); 910EXPORT_SYMBOL_GPL(ps3av_video_mute);
916 911
917/* mute analog output only */ 912/* mute analog output only */
@@ -935,7 +930,6 @@ int ps3av_audio_mute(int mute)
935 return ps3av_set_audio_mute(mute ? PS3AV_CMD_MUTE_ON 930 return ps3av_set_audio_mute(mute ? PS3AV_CMD_MUTE_ON
936 : PS3AV_CMD_MUTE_OFF); 931 : PS3AV_CMD_MUTE_OFF);
937} 932}
938
939EXPORT_SYMBOL_GPL(ps3av_audio_mute); 933EXPORT_SYMBOL_GPL(ps3av_audio_mute);
940 934
941static int __devinit ps3av_probe(struct ps3_system_bus_device *dev) 935static int __devinit ps3av_probe(struct ps3_system_bus_device *dev)