diff options
author | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2012-04-30 00:49:17 -0400 |
---|---|---|
committer | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2012-04-30 00:49:17 -0400 |
commit | 76ef6a25ce2a1fbb9a51c553c93d2ad74f0f9185 (patch) | |
tree | 6e71c8bcc2a2d48657be28cb07963f969bc2d626 /drivers | |
parent | 69964ea4c7b68c9399f7977aa5b9aa6539a6a98a (diff) | |
parent | 3252c8a3d0bf3c6af6ce7c76c40444943cda2943 (diff) |
Merge remote-tracking branch 'geoff/for-powerpc' into next
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/ps3/ps3av.c | 24 |
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: | 341 | err: |
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 | |||
481 | EXPORT_SYMBOL_GPL(ps3av_set_audio_mode); | 480 | EXPORT_SYMBOL_GPL(ps3av_set_audio_mode); |
482 | 481 | ||
483 | static int ps3av_set_videomode(void) | 482 | static 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 | ||
592 | static const struct { | 591 | static 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 | ||
670 | static void ps3av_monitor_info_dump(const struct ps3av_pkt_av_get_monitor_info *monitor_info) | 669 | static 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 | |||
874 | EXPORT_SYMBOL_GPL(ps3av_set_video_mode); | 873 | EXPORT_SYMBOL_GPL(ps3av_set_video_mode); |
875 | 874 | ||
876 | int ps3av_get_auto_mode(void) | 875 | int 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 | |||
881 | EXPORT_SYMBOL_GPL(ps3av_get_auto_mode); | 879 | EXPORT_SYMBOL_GPL(ps3av_get_auto_mode); |
882 | 880 | ||
883 | int ps3av_get_mode(void) | 881 | int ps3av_get_mode(void) |
884 | { | 882 | { |
885 | return ps3av ? ps3av->ps3av_mode : 0; | 883 | return ps3av ? ps3av->ps3av_mode : 0; |
886 | } | 884 | } |
887 | |||
888 | EXPORT_SYMBOL_GPL(ps3av_get_mode); | 885 | EXPORT_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 | |||
906 | EXPORT_SYMBOL_GPL(ps3av_video_mode2res); | 902 | EXPORT_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 | |||
915 | EXPORT_SYMBOL_GPL(ps3av_video_mute); | 910 | EXPORT_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 | |||
939 | EXPORT_SYMBOL_GPL(ps3av_audio_mute); | 933 | EXPORT_SYMBOL_GPL(ps3av_audio_mute); |
940 | 934 | ||
941 | static int __devinit ps3av_probe(struct ps3_system_bus_device *dev) | 935 | static int __devinit ps3av_probe(struct ps3_system_bus_device *dev) |