diff options
Diffstat (limited to 'sound/ppc/pmac.c')
-rw-r--r-- | sound/ppc/pmac.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/sound/ppc/pmac.c b/sound/ppc/pmac.c index c64af55865d4..5e829683d1ad 100644 --- a/sound/ppc/pmac.c +++ b/sound/ppc/pmac.c | |||
@@ -864,7 +864,8 @@ static void __init detect_byte_swap(struct snd_pmac *chip) | |||
864 | static int __init snd_pmac_detect(struct snd_pmac *chip) | 864 | static int __init snd_pmac_detect(struct snd_pmac *chip) |
865 | { | 865 | { |
866 | struct device_node *sound = NULL; | 866 | struct device_node *sound = NULL; |
867 | unsigned int *prop, l; | 867 | const unsigned int *prop; |
868 | unsigned int l; | ||
868 | struct macio_chip* macio; | 869 | struct macio_chip* macio; |
869 | 870 | ||
870 | if (!machine_is(powermac)) | 871 | if (!machine_is(powermac)) |
@@ -923,10 +924,10 @@ static int __init snd_pmac_detect(struct snd_pmac *chip) | |||
923 | } | 924 | } |
924 | if (! sound) | 925 | if (! sound) |
925 | return -ENODEV; | 926 | return -ENODEV; |
926 | prop = (unsigned int *) get_property(sound, "sub-frame", NULL); | 927 | prop = of_get_property(sound, "sub-frame", NULL); |
927 | if (prop && *prop < 16) | 928 | if (prop && *prop < 16) |
928 | chip->subframe = *prop; | 929 | chip->subframe = *prop; |
929 | prop = (unsigned int *) get_property(sound, "layout-id", NULL); | 930 | prop = of_get_property(sound, "layout-id", NULL); |
930 | if (prop) { | 931 | if (prop) { |
931 | /* partly deprecate snd-powermac, for those machines | 932 | /* partly deprecate snd-powermac, for those machines |
932 | * that have a layout-id property for now */ | 933 | * that have a layout-id property for now */ |
@@ -967,7 +968,7 @@ static int __init snd_pmac_detect(struct snd_pmac *chip) | |||
967 | chip->freq_table = tumbler_freqs; | 968 | chip->freq_table = tumbler_freqs; |
968 | chip->control_mask = MASK_IEPC | 0x11; /* disable IEE */ | 969 | chip->control_mask = MASK_IEPC | 0x11; /* disable IEE */ |
969 | } | 970 | } |
970 | prop = (unsigned int *)get_property(sound, "device-id", NULL); | 971 | prop = of_get_property(sound, "device-id", NULL); |
971 | if (prop) | 972 | if (prop) |
972 | chip->device_id = *prop; | 973 | chip->device_id = *prop; |
973 | chip->has_iic = (find_devices("perch") != NULL); | 974 | chip->has_iic = (find_devices("perch") != NULL); |
@@ -997,10 +998,9 @@ static int __init snd_pmac_detect(struct snd_pmac *chip) | |||
997 | 998 | ||
998 | /* look for a property saying what sample rates | 999 | /* look for a property saying what sample rates |
999 | are available */ | 1000 | are available */ |
1000 | prop = (unsigned int *) get_property(sound, "sample-rates", &l); | 1001 | prop = of_get_property(sound, "sample-rates", &l); |
1001 | if (! prop) | 1002 | if (! prop) |
1002 | prop = (unsigned int *) get_property(sound, | 1003 | prop = of_get_property(sound, "output-frame-rates", &l); |
1003 | "output-frame-rates", &l); | ||
1004 | if (prop) { | 1004 | if (prop) { |
1005 | int i; | 1005 | int i; |
1006 | chip->freqs_ok = 0; | 1006 | chip->freqs_ok = 0; |