Commit 5944b2ce5778f2a9c5eb4805cf8569feb2b4ed49
Committed by
Jens Axboe
1 parent
fc27691f35
Exists in
ti-lsk-linux-4.1.y
and in
10 other branches
cdrom: convert cdinfo to cd_dbg
It's a debugging message, mark it so. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Jens Axboe <axboe@fb.com>
Showing 1 changed file with 121 additions and 120 deletions Side-by-side Diff
drivers/cdrom/cdrom.c
... | ... | @@ -312,17 +312,17 @@ |
312 | 312 | |
313 | 313 | static const char *mrw_address_space[] = { "DMA", "GAA" }; |
314 | 314 | |
315 | -#if (ERRLOGMASK!=CD_NOTHING) | |
316 | -#define cdinfo(type, fmt, args...) \ | |
315 | +#if (ERRLOGMASK != CD_NOTHING) | |
316 | +#define cd_dbg(type, fmt, ...) \ | |
317 | 317 | do { \ |
318 | 318 | if ((ERRLOGMASK & type) || debug == 1) \ |
319 | - pr_info(fmt, ##args); \ | |
319 | + pr_debug(fmt, ##__VA_ARGS__); \ | |
320 | 320 | } while (0) |
321 | 321 | #else |
322 | -#define cdinfo(type, fmt, args...) \ | |
322 | +#define cd_dbg(type, fmt, ...) \ | |
323 | 323 | do { \ |
324 | 324 | if (0 && (ERRLOGMASK & type) || debug == 1) \ |
325 | - pr_info(fmt, ##args); \ | |
325 | + pr_debug(fmt, ##__VA_ARGS__); \ | |
326 | 326 | } while (0) |
327 | 327 | #endif |
328 | 328 | |
... | ... | @@ -395,7 +395,7 @@ |
395 | 395 | struct cdrom_device_ops *cdo = cdi->ops; |
396 | 396 | int *change_capability = (int *)&cdo->capability; /* hack */ |
397 | 397 | |
398 | - cdinfo(CD_OPEN, "entering register_cdrom\n"); | |
398 | + cd_dbg(CD_OPEN, "entering register_cdrom\n"); | |
399 | 399 | |
400 | 400 | if (cdo->open == NULL || cdo->release == NULL) |
401 | 401 | return -EINVAL; |
... | ... | @@ -439,7 +439,7 @@ |
439 | 439 | if (!cdo->generic_packet) |
440 | 440 | cdo->generic_packet = cdrom_dummy_generic_packet; |
441 | 441 | |
442 | - cdinfo(CD_REG_UNREG, "drive \"/dev/%s\" registered\n", cdi->name); | |
442 | + cd_dbg(CD_REG_UNREG, "drive \"/dev/%s\" registered\n", cdi->name); | |
443 | 443 | mutex_lock(&cdrom_mutex); |
444 | 444 | list_add(&cdi->list, &cdrom_list); |
445 | 445 | mutex_unlock(&cdrom_mutex); |
... | ... | @@ -449,7 +449,7 @@ |
449 | 449 | |
450 | 450 | void unregister_cdrom(struct cdrom_device_info *cdi) |
451 | 451 | { |
452 | - cdinfo(CD_OPEN, "entering unregister_cdrom\n"); | |
452 | + cd_dbg(CD_OPEN, "entering unregister_cdrom\n"); | |
453 | 453 | |
454 | 454 | mutex_lock(&cdrom_mutex); |
455 | 455 | list_del(&cdi->list); |
... | ... | @@ -459,7 +459,7 @@ |
459 | 459 | cdi->exit(cdi); |
460 | 460 | |
461 | 461 | cdi->ops->n_minors--; |
462 | - cdinfo(CD_REG_UNREG, "drive \"/dev/%s\" unregistered\n", cdi->name); | |
462 | + cd_dbg(CD_REG_UNREG, "drive \"/dev/%s\" unregistered\n", cdi->name); | |
463 | 463 | } |
464 | 464 | |
465 | 465 | int cdrom_get_media_event(struct cdrom_device_info *cdi, |
... | ... | @@ -839,7 +839,7 @@ |
839 | 839 | else if (CDF_RWRT == be16_to_cpu(rfd.feature_code)) |
840 | 840 | ret = !rfd.curr; |
841 | 841 | |
842 | - cdinfo(CD_OPEN, "can open for random write\n"); | |
842 | + cd_dbg(CD_OPEN, "can open for random write\n"); | |
843 | 843 | return ret; |
844 | 844 | } |
845 | 845 | |
846 | 846 | |
... | ... | @@ -928,12 +928,12 @@ |
928 | 928 | struct packet_command cgc; |
929 | 929 | |
930 | 930 | if (cdi->mmc3_profile != 0x1a) { |
931 | - cdinfo(CD_CLOSE, "%s: No DVD+RW\n", cdi->name); | |
931 | + cd_dbg(CD_CLOSE, "%s: No DVD+RW\n", cdi->name); | |
932 | 932 | return; |
933 | 933 | } |
934 | 934 | |
935 | 935 | if (!cdi->media_written) { |
936 | - cdinfo(CD_CLOSE, "%s: DVD+RW media clean\n", cdi->name); | |
936 | + cd_dbg(CD_CLOSE, "%s: DVD+RW media clean\n", cdi->name); | |
937 | 937 | return; |
938 | 938 | } |
939 | 939 | |
... | ... | @@ -981,7 +981,7 @@ |
981 | 981 | { |
982 | 982 | int ret; |
983 | 983 | |
984 | - cdinfo(CD_OPEN, "entering cdrom_open\n"); | |
984 | + cd_dbg(CD_OPEN, "entering cdrom_open\n"); | |
985 | 985 | |
986 | 986 | /* open is event synchronization point, check events first */ |
987 | 987 | check_disk_change(bdev); |
988 | 988 | |
... | ... | @@ -1010,13 +1010,13 @@ |
1010 | 1010 | if (ret) |
1011 | 1011 | goto err; |
1012 | 1012 | |
1013 | - cdinfo(CD_OPEN, "Use count for \"/dev/%s\" now %d\n", | |
1014 | - cdi->name, cdi->use_count); | |
1013 | + cd_dbg(CD_OPEN, "Use count for \"/dev/%s\" now %d\n", | |
1014 | + cdi->name, cdi->use_count); | |
1015 | 1015 | return 0; |
1016 | 1016 | err_release: |
1017 | 1017 | if (CDROM_CAN(CDC_LOCK) && cdi->options & CDO_LOCK) { |
1018 | 1018 | cdi->ops->lock_door(cdi, 0); |
1019 | - cdinfo(CD_OPEN, "door unlocked.\n"); | |
1019 | + cd_dbg(CD_OPEN, "door unlocked\n"); | |
1020 | 1020 | } |
1021 | 1021 | cdi->ops->release(cdi); |
1022 | 1022 | err: |
1023 | 1023 | |
1024 | 1024 | |
1025 | 1025 | |
1026 | 1026 | |
... | ... | @@ -1030,21 +1030,21 @@ |
1030 | 1030 | int ret; |
1031 | 1031 | struct cdrom_device_ops *cdo = cdi->ops; |
1032 | 1032 | tracktype tracks; |
1033 | - cdinfo(CD_OPEN, "entering open_for_data\n"); | |
1033 | + cd_dbg(CD_OPEN, "entering open_for_data\n"); | |
1034 | 1034 | /* Check if the driver can report drive status. If it can, we |
1035 | 1035 | can do clever things. If it can't, well, we at least tried! */ |
1036 | 1036 | if (cdo->drive_status != NULL) { |
1037 | 1037 | ret = cdo->drive_status(cdi, CDSL_CURRENT); |
1038 | - cdinfo(CD_OPEN, "drive_status=%d\n", ret); | |
1038 | + cd_dbg(CD_OPEN, "drive_status=%d\n", ret); | |
1039 | 1039 | if (ret == CDS_TRAY_OPEN) { |
1040 | - cdinfo(CD_OPEN, "the tray is open...\n"); | |
1040 | + cd_dbg(CD_OPEN, "the tray is open...\n"); | |
1041 | 1041 | /* can/may i close it? */ |
1042 | 1042 | if (CDROM_CAN(CDC_CLOSE_TRAY) && |
1043 | 1043 | cdi->options & CDO_AUTO_CLOSE) { |
1044 | - cdinfo(CD_OPEN, "trying to close the tray.\n"); | |
1044 | + cd_dbg(CD_OPEN, "trying to close the tray\n"); | |
1045 | 1045 | ret=cdo->tray_move(cdi,0); |
1046 | 1046 | if (ret) { |
1047 | - cdinfo(CD_OPEN, "bummer. tried to close the tray but failed.\n"); | |
1047 | + cd_dbg(CD_OPEN, "bummer. tried to close the tray but failed.\n"); | |
1048 | 1048 | /* Ignore the error from the low |
1049 | 1049 | level driver. We don't care why it |
1050 | 1050 | couldn't close the tray. We only care |
1051 | 1051 | |
1052 | 1052 | |
... | ... | @@ -1054,19 +1054,19 @@ |
1054 | 1054 | goto clean_up_and_return; |
1055 | 1055 | } |
1056 | 1056 | } else { |
1057 | - cdinfo(CD_OPEN, "bummer. this drive can't close the tray.\n"); | |
1057 | + cd_dbg(CD_OPEN, "bummer. this drive can't close the tray.\n"); | |
1058 | 1058 | ret=-ENOMEDIUM; |
1059 | 1059 | goto clean_up_and_return; |
1060 | 1060 | } |
1061 | 1061 | /* Ok, the door should be closed now.. Check again */ |
1062 | 1062 | ret = cdo->drive_status(cdi, CDSL_CURRENT); |
1063 | 1063 | if ((ret == CDS_NO_DISC) || (ret==CDS_TRAY_OPEN)) { |
1064 | - cdinfo(CD_OPEN, "bummer. the tray is still not closed.\n"); | |
1065 | - cdinfo(CD_OPEN, "tray might not contain a medium.\n"); | |
1064 | + cd_dbg(CD_OPEN, "bummer. the tray is still not closed.\n"); | |
1065 | + cd_dbg(CD_OPEN, "tray might not contain a medium\n"); | |
1066 | 1066 | ret=-ENOMEDIUM; |
1067 | 1067 | goto clean_up_and_return; |
1068 | 1068 | } |
1069 | - cdinfo(CD_OPEN, "the tray is now closed.\n"); | |
1069 | + cd_dbg(CD_OPEN, "the tray is now closed\n"); | |
1070 | 1070 | } |
1071 | 1071 | /* the door should be closed now, check for the disc */ |
1072 | 1072 | ret = cdo->drive_status(cdi, CDSL_CURRENT); |
... | ... | @@ -1077,7 +1077,7 @@ |
1077 | 1077 | } |
1078 | 1078 | cdrom_count_tracks(cdi, &tracks); |
1079 | 1079 | if (tracks.error == CDS_NO_DISC) { |
1080 | - cdinfo(CD_OPEN, "bummer. no disc.\n"); | |
1080 | + cd_dbg(CD_OPEN, "bummer. no disc.\n"); | |
1081 | 1081 | ret=-ENOMEDIUM; |
1082 | 1082 | goto clean_up_and_return; |
1083 | 1083 | } |
1084 | 1084 | |
1085 | 1085 | |
1086 | 1086 | |
1087 | 1087 | |
1088 | 1088 | |
1089 | 1089 | |
... | ... | @@ -1087,34 +1087,34 @@ |
1087 | 1087 | if (cdi->options & CDO_CHECK_TYPE) { |
1088 | 1088 | /* give people a warning shot, now that CDO_CHECK_TYPE |
1089 | 1089 | is the default case! */ |
1090 | - cdinfo(CD_OPEN, "bummer. wrong media type.\n"); | |
1091 | - cdinfo(CD_WARNING, "pid %d must open device O_NONBLOCK!\n", | |
1092 | - (unsigned int)task_pid_nr(current)); | |
1090 | + cd_dbg(CD_OPEN, "bummer. wrong media type.\n"); | |
1091 | + cd_dbg(CD_WARNING, "pid %d must open device O_NONBLOCK!\n", | |
1092 | + (unsigned int)task_pid_nr(current)); | |
1093 | 1093 | ret=-EMEDIUMTYPE; |
1094 | 1094 | goto clean_up_and_return; |
1095 | 1095 | } |
1096 | 1096 | else { |
1097 | - cdinfo(CD_OPEN, "wrong media type, but CDO_CHECK_TYPE not set.\n"); | |
1097 | + cd_dbg(CD_OPEN, "wrong media type, but CDO_CHECK_TYPE not set\n"); | |
1098 | 1098 | } |
1099 | 1099 | } |
1100 | 1100 | |
1101 | - cdinfo(CD_OPEN, "all seems well, opening the device.\n"); | |
1101 | + cd_dbg(CD_OPEN, "all seems well, opening the devicen"); | |
1102 | 1102 | |
1103 | 1103 | /* all seems well, we can open the device */ |
1104 | 1104 | ret = cdo->open(cdi, 0); /* open for data */ |
1105 | - cdinfo(CD_OPEN, "opening the device gave me %d.\n", ret); | |
1105 | + cd_dbg(CD_OPEN, "opening the device gave me %d\n", ret); | |
1106 | 1106 | /* After all this careful checking, we shouldn't have problems |
1107 | 1107 | opening the device, but we don't want the device locked if |
1108 | 1108 | this somehow fails... */ |
1109 | 1109 | if (ret) { |
1110 | - cdinfo(CD_OPEN, "open device failed.\n"); | |
1110 | + cd_dbg(CD_OPEN, "open device failed\n"); | |
1111 | 1111 | goto clean_up_and_return; |
1112 | 1112 | } |
1113 | 1113 | if (CDROM_CAN(CDC_LOCK) && (cdi->options & CDO_LOCK)) { |
1114 | 1114 | cdo->lock_door(cdi, 1); |
1115 | - cdinfo(CD_OPEN, "door locked.\n"); | |
1115 | + cd_dbg(CD_OPEN, "door locked\n"); | |
1116 | 1116 | } |
1117 | - cdinfo(CD_OPEN, "device opened successfully.\n"); | |
1117 | + cd_dbg(CD_OPEN, "device opened successfully\n"); | |
1118 | 1118 | return ret; |
1119 | 1119 | |
1120 | 1120 | /* Something failed. Try to unlock the drive, because some drivers |
1121 | 1121 | |
... | ... | @@ -1123,10 +1123,10 @@ |
1123 | 1123 | This ensures that the drive gets unlocked after a mount fails. This |
1124 | 1124 | is a goto to avoid bloating the driver with redundant code. */ |
1125 | 1125 | clean_up_and_return: |
1126 | - cdinfo(CD_OPEN, "open failed.\n"); | |
1126 | + cd_dbg(CD_OPEN, "open failed\n"); | |
1127 | 1127 | if (CDROM_CAN(CDC_LOCK) && cdi->options & CDO_LOCK) { |
1128 | 1128 | cdo->lock_door(cdi, 0); |
1129 | - cdinfo(CD_OPEN, "door unlocked.\n"); | |
1129 | + cd_dbg(CD_OPEN, "door unlocked\n"); | |
1130 | 1130 | } |
1131 | 1131 | return ret; |
1132 | 1132 | } |
1133 | 1133 | |
1134 | 1134 | |
1135 | 1135 | |
1136 | 1136 | |
... | ... | @@ -1139,21 +1139,21 @@ |
1139 | 1139 | { |
1140 | 1140 | int ret; |
1141 | 1141 | tracktype tracks; |
1142 | - cdinfo(CD_OPEN, "entering check_for_audio_disc\n"); | |
1142 | + cd_dbg(CD_OPEN, "entering check_for_audio_disc\n"); | |
1143 | 1143 | if (!(cdi->options & CDO_CHECK_TYPE)) |
1144 | 1144 | return 0; |
1145 | 1145 | if (cdo->drive_status != NULL) { |
1146 | 1146 | ret = cdo->drive_status(cdi, CDSL_CURRENT); |
1147 | - cdinfo(CD_OPEN, "drive_status=%d\n", ret); | |
1147 | + cd_dbg(CD_OPEN, "drive_status=%d\n", ret); | |
1148 | 1148 | if (ret == CDS_TRAY_OPEN) { |
1149 | - cdinfo(CD_OPEN, "the tray is open...\n"); | |
1149 | + cd_dbg(CD_OPEN, "the tray is open...\n"); | |
1150 | 1150 | /* can/may i close it? */ |
1151 | 1151 | if (CDROM_CAN(CDC_CLOSE_TRAY) && |
1152 | 1152 | cdi->options & CDO_AUTO_CLOSE) { |
1153 | - cdinfo(CD_OPEN, "trying to close the tray.\n"); | |
1153 | + cd_dbg(CD_OPEN, "trying to close the tray\n"); | |
1154 | 1154 | ret=cdo->tray_move(cdi,0); |
1155 | 1155 | if (ret) { |
1156 | - cdinfo(CD_OPEN, "bummer. tried to close tray but failed.\n"); | |
1156 | + cd_dbg(CD_OPEN, "bummer. tried to close tray but failed.\n"); | |
1157 | 1157 | /* Ignore the error from the low |
1158 | 1158 | level driver. We don't care why it |
1159 | 1159 | couldn't close the tray. We only care |
1160 | 1160 | |
1161 | 1161 | |
1162 | 1162 | |
... | ... | @@ -1162,20 +1162,20 @@ |
1162 | 1162 | return -ENOMEDIUM; |
1163 | 1163 | } |
1164 | 1164 | } else { |
1165 | - cdinfo(CD_OPEN, "bummer. this driver can't close the tray.\n"); | |
1165 | + cd_dbg(CD_OPEN, "bummer. this driver can't close the tray.\n"); | |
1166 | 1166 | return -ENOMEDIUM; |
1167 | 1167 | } |
1168 | 1168 | /* Ok, the door should be closed now.. Check again */ |
1169 | 1169 | ret = cdo->drive_status(cdi, CDSL_CURRENT); |
1170 | 1170 | if ((ret == CDS_NO_DISC) || (ret==CDS_TRAY_OPEN)) { |
1171 | - cdinfo(CD_OPEN, "bummer. the tray is still not closed.\n"); | |
1171 | + cd_dbg(CD_OPEN, "bummer. the tray is still not closed.\n"); | |
1172 | 1172 | return -ENOMEDIUM; |
1173 | 1173 | } |
1174 | 1174 | if (ret!=CDS_DISC_OK) { |
1175 | - cdinfo(CD_OPEN, "bummer. disc isn't ready.\n"); | |
1175 | + cd_dbg(CD_OPEN, "bummer. disc isn't ready.\n"); | |
1176 | 1176 | return -EIO; |
1177 | 1177 | } |
1178 | - cdinfo(CD_OPEN, "the tray is now closed.\n"); | |
1178 | + cd_dbg(CD_OPEN, "the tray is now closed\n"); | |
1179 | 1179 | } |
1180 | 1180 | } |
1181 | 1181 | cdrom_count_tracks(cdi, &tracks); |
1182 | 1182 | |
1183 | 1183 | |
... | ... | @@ -1193,17 +1193,18 @@ |
1193 | 1193 | struct cdrom_device_ops *cdo = cdi->ops; |
1194 | 1194 | int opened_for_data; |
1195 | 1195 | |
1196 | - cdinfo(CD_CLOSE, "entering cdrom_release\n"); | |
1196 | + cd_dbg(CD_CLOSE, "entering cdrom_release\n"); | |
1197 | 1197 | |
1198 | 1198 | if (cdi->use_count > 0) |
1199 | 1199 | cdi->use_count--; |
1200 | 1200 | |
1201 | 1201 | if (cdi->use_count == 0) { |
1202 | - cdinfo(CD_CLOSE, "Use count for \"/dev/%s\" now zero\n", cdi->name); | |
1202 | + cd_dbg(CD_CLOSE, "Use count for \"/dev/%s\" now zero\n", | |
1203 | + cdi->name); | |
1203 | 1204 | cdrom_dvd_rw_close_write(cdi); |
1204 | 1205 | |
1205 | 1206 | if ((cdo->capability & CDC_LOCK) && !cdi->keeplocked) { |
1206 | - cdinfo(CD_CLOSE, "Unlocking door!\n"); | |
1207 | + cd_dbg(CD_CLOSE, "Unlocking door!\n"); | |
1207 | 1208 | cdo->lock_door(cdi, 0); |
1208 | 1209 | } |
1209 | 1210 | } |
... | ... | @@ -1262,7 +1263,7 @@ |
1262 | 1263 | struct cdrom_changer_info *info; |
1263 | 1264 | int ret; |
1264 | 1265 | |
1265 | - cdinfo(CD_CHANGER, "entering cdrom_slot_status()\n"); | |
1266 | + cd_dbg(CD_CHANGER, "entering cdrom_slot_status()\n"); | |
1266 | 1267 | if (cdi->sanyo_slot) |
1267 | 1268 | return CDS_NO_INFO; |
1268 | 1269 | |
... | ... | @@ -1292,7 +1293,7 @@ |
1292 | 1293 | int nslots = 1; |
1293 | 1294 | struct cdrom_changer_info *info; |
1294 | 1295 | |
1295 | - cdinfo(CD_CHANGER, "entering cdrom_number_of_slots()\n"); | |
1296 | + cd_dbg(CD_CHANGER, "entering cdrom_number_of_slots()\n"); | |
1296 | 1297 | /* cdrom_read_mech_status requires a valid value for capacity: */ |
1297 | 1298 | cdi->capacity = 0; |
1298 | 1299 | |
... | ... | @@ -1313,7 +1314,7 @@ |
1313 | 1314 | { |
1314 | 1315 | struct packet_command cgc; |
1315 | 1316 | |
1316 | - cdinfo(CD_CHANGER, "entering cdrom_load_unload()\n"); | |
1317 | + cd_dbg(CD_CHANGER, "entering cdrom_load_unload()\n"); | |
1317 | 1318 | if (cdi->sanyo_slot && slot < 0) |
1318 | 1319 | return 0; |
1319 | 1320 | |
... | ... | @@ -1342,7 +1343,7 @@ |
1342 | 1343 | int curslot; |
1343 | 1344 | int ret; |
1344 | 1345 | |
1345 | - cdinfo(CD_CHANGER, "entering cdrom_select_disc()\n"); | |
1346 | + cd_dbg(CD_CHANGER, "entering cdrom_select_disc()\n"); | |
1346 | 1347 | if (!CDROM_CAN(CDC_SELECT_DISC)) |
1347 | 1348 | return -EDRIVE_CANT_DO_THIS; |
1348 | 1349 | |
... | ... | @@ -1487,7 +1488,7 @@ |
1487 | 1488 | tracks->cdi=0; |
1488 | 1489 | tracks->xa=0; |
1489 | 1490 | tracks->error=0; |
1490 | - cdinfo(CD_COUNT_TRACKS, "entering cdrom_count_tracks\n"); | |
1491 | + cd_dbg(CD_COUNT_TRACKS, "entering cdrom_count_tracks\n"); | |
1491 | 1492 | /* Grab the TOC header so we can see how many tracks there are */ |
1492 | 1493 | if ((ret = cdi->ops->audio_ioctl(cdi, CDROMREADTOCHDR, &header))) { |
1493 | 1494 | if (ret == -ENOMEDIUM) |
1494 | 1495 | |
... | ... | @@ -1513,12 +1514,12 @@ |
1513 | 1514 | tracks->data++; |
1514 | 1515 | } else |
1515 | 1516 | tracks->audio++; |
1516 | - cdinfo(CD_COUNT_TRACKS, "track %d: format=%d, ctrl=%d\n", | |
1517 | + cd_dbg(CD_COUNT_TRACKS, "track %d: format=%d, ctrl=%d\n", | |
1517 | 1518 | i, entry.cdte_format, entry.cdte_ctrl); |
1518 | 1519 | } |
1519 | - cdinfo(CD_COUNT_TRACKS, "disc has %d tracks: %d=audio %d=data %d=Cd-I %d=XA\n", | |
1520 | - header.cdth_trk1, tracks->audio, tracks->data, | |
1521 | - tracks->cdi, tracks->xa); | |
1520 | + cd_dbg(CD_COUNT_TRACKS, "disc has %d tracks: %d=audio %d=data %d=Cd-I %d=XA\n", | |
1521 | + header.cdth_trk1, tracks->audio, tracks->data, | |
1522 | + tracks->cdi, tracks->xa); | |
1522 | 1523 | } |
1523 | 1524 | |
1524 | 1525 | /* Requests to the low-level drivers will /always/ be done in the |
... | ... | @@ -1632,7 +1633,7 @@ |
1632 | 1633 | switch (ai->type) { |
1633 | 1634 | /* LU data send */ |
1634 | 1635 | case DVD_LU_SEND_AGID: |
1635 | - cdinfo(CD_DVD, "entering DVD_LU_SEND_AGID\n"); | |
1636 | + cd_dbg(CD_DVD, "entering DVD_LU_SEND_AGID\n"); | |
1636 | 1637 | cgc.quiet = 1; |
1637 | 1638 | setup_report_key(&cgc, ai->lsa.agid, 0); |
1638 | 1639 | |
... | ... | @@ -1644,7 +1645,7 @@ |
1644 | 1645 | break; |
1645 | 1646 | |
1646 | 1647 | case DVD_LU_SEND_KEY1: |
1647 | - cdinfo(CD_DVD, "entering DVD_LU_SEND_KEY1\n"); | |
1648 | + cd_dbg(CD_DVD, "entering DVD_LU_SEND_KEY1\n"); | |
1648 | 1649 | setup_report_key(&cgc, ai->lsk.agid, 2); |
1649 | 1650 | |
1650 | 1651 | if ((ret = cdo->generic_packet(cdi, &cgc))) |
... | ... | @@ -1655,7 +1656,7 @@ |
1655 | 1656 | break; |
1656 | 1657 | |
1657 | 1658 | case DVD_LU_SEND_CHALLENGE: |
1658 | - cdinfo(CD_DVD, "entering DVD_LU_SEND_CHALLENGE\n"); | |
1659 | + cd_dbg(CD_DVD, "entering DVD_LU_SEND_CHALLENGE\n"); | |
1659 | 1660 | setup_report_key(&cgc, ai->lsc.agid, 1); |
1660 | 1661 | |
1661 | 1662 | if ((ret = cdo->generic_packet(cdi, &cgc))) |
... | ... | @@ -1667,7 +1668,7 @@ |
1667 | 1668 | |
1668 | 1669 | /* Post-auth key */ |
1669 | 1670 | case DVD_LU_SEND_TITLE_KEY: |
1670 | - cdinfo(CD_DVD, "entering DVD_LU_SEND_TITLE_KEY\n"); | |
1671 | + cd_dbg(CD_DVD, "entering DVD_LU_SEND_TITLE_KEY\n"); | |
1671 | 1672 | cgc.quiet = 1; |
1672 | 1673 | setup_report_key(&cgc, ai->lstk.agid, 4); |
1673 | 1674 | cgc.cmd[5] = ai->lstk.lba; |
... | ... | @@ -1686,7 +1687,7 @@ |
1686 | 1687 | break; |
1687 | 1688 | |
1688 | 1689 | case DVD_LU_SEND_ASF: |
1689 | - cdinfo(CD_DVD, "entering DVD_LU_SEND_ASF\n"); | |
1690 | + cd_dbg(CD_DVD, "entering DVD_LU_SEND_ASF\n"); | |
1690 | 1691 | setup_report_key(&cgc, ai->lsasf.agid, 5); |
1691 | 1692 | |
1692 | 1693 | if ((ret = cdo->generic_packet(cdi, &cgc))) |
... | ... | @@ -1697,7 +1698,7 @@ |
1697 | 1698 | |
1698 | 1699 | /* LU data receive (LU changes state) */ |
1699 | 1700 | case DVD_HOST_SEND_CHALLENGE: |
1700 | - cdinfo(CD_DVD, "entering DVD_HOST_SEND_CHALLENGE\n"); | |
1701 | + cd_dbg(CD_DVD, "entering DVD_HOST_SEND_CHALLENGE\n"); | |
1701 | 1702 | setup_send_key(&cgc, ai->hsc.agid, 1); |
1702 | 1703 | buf[1] = 0xe; |
1703 | 1704 | copy_chal(&buf[4], ai->hsc.chal); |
... | ... | @@ -1709,7 +1710,7 @@ |
1709 | 1710 | break; |
1710 | 1711 | |
1711 | 1712 | case DVD_HOST_SEND_KEY2: |
1712 | - cdinfo(CD_DVD, "entering DVD_HOST_SEND_KEY2\n"); | |
1713 | + cd_dbg(CD_DVD, "entering DVD_HOST_SEND_KEY2\n"); | |
1713 | 1714 | setup_send_key(&cgc, ai->hsk.agid, 3); |
1714 | 1715 | buf[1] = 0xa; |
1715 | 1716 | copy_key(&buf[4], ai->hsk.key); |
... | ... | @@ -1724,7 +1725,7 @@ |
1724 | 1725 | /* Misc */ |
1725 | 1726 | case DVD_INVALIDATE_AGID: |
1726 | 1727 | cgc.quiet = 1; |
1727 | - cdinfo(CD_DVD, "entering DVD_INVALIDATE_AGID\n"); | |
1728 | + cd_dbg(CD_DVD, "entering DVD_INVALIDATE_AGID\n"); | |
1728 | 1729 | setup_report_key(&cgc, ai->lsa.agid, 0x3f); |
1729 | 1730 | if ((ret = cdo->generic_packet(cdi, &cgc))) |
1730 | 1731 | return ret; |
... | ... | @@ -1732,7 +1733,7 @@ |
1732 | 1733 | |
1733 | 1734 | /* Get region settings */ |
1734 | 1735 | case DVD_LU_SEND_RPC_STATE: |
1735 | - cdinfo(CD_DVD, "entering DVD_LU_SEND_RPC_STATE\n"); | |
1736 | + cd_dbg(CD_DVD, "entering DVD_LU_SEND_RPC_STATE\n"); | |
1736 | 1737 | setup_report_key(&cgc, 0, 8); |
1737 | 1738 | memset(&rpc_state, 0, sizeof(rpc_state_t)); |
1738 | 1739 | cgc.buffer = (char *) &rpc_state; |
... | ... | @@ -1749,7 +1750,7 @@ |
1749 | 1750 | |
1750 | 1751 | /* Set region settings */ |
1751 | 1752 | case DVD_HOST_SEND_RPC_STATE: |
1752 | - cdinfo(CD_DVD, "entering DVD_HOST_SEND_RPC_STATE\n"); | |
1753 | + cd_dbg(CD_DVD, "entering DVD_HOST_SEND_RPC_STATE\n"); | |
1753 | 1754 | setup_send_key(&cgc, 0, 6); |
1754 | 1755 | buf[1] = 6; |
1755 | 1756 | buf[4] = ai->hrpcs.pdrc; |
... | ... | @@ -1759,7 +1760,7 @@ |
1759 | 1760 | break; |
1760 | 1761 | |
1761 | 1762 | default: |
1762 | - cdinfo(CD_WARNING, "Invalid DVD key ioctl (%d)\n", ai->type); | |
1763 | + cd_dbg(CD_WARNING, "Invalid DVD key ioctl (%d)\n", ai->type); | |
1763 | 1764 | return -ENOTTY; |
1764 | 1765 | } |
1765 | 1766 | |
... | ... | @@ -1891,7 +1892,8 @@ |
1891 | 1892 | |
1892 | 1893 | s->bca.len = buf[0] << 8 | buf[1]; |
1893 | 1894 | if (s->bca.len < 12 || s->bca.len > 188) { |
1894 | - cdinfo(CD_WARNING, "Received invalid BCA length (%d)\n", s->bca.len); | |
1895 | + cd_dbg(CD_WARNING, "Received invalid BCA length (%d)\n", | |
1896 | + s->bca.len); | |
1895 | 1897 | ret = -EIO; |
1896 | 1898 | goto out; |
1897 | 1899 | } |
1898 | 1900 | |
... | ... | @@ -1927,14 +1929,13 @@ |
1927 | 1929 | |
1928 | 1930 | s->manufact.len = buf[0] << 8 | buf[1]; |
1929 | 1931 | if (s->manufact.len < 0) { |
1930 | - cdinfo(CD_WARNING, "Received invalid manufacture info length" | |
1931 | - " (%d)\n", s->manufact.len); | |
1932 | + cd_dbg(CD_WARNING, "Received invalid manufacture info length (%d)\n", | |
1933 | + s->manufact.len); | |
1932 | 1934 | ret = -EIO; |
1933 | 1935 | } else { |
1934 | 1936 | if (s->manufact.len > 2048) { |
1935 | - cdinfo(CD_WARNING, "Received invalid manufacture info " | |
1936 | - "length (%d): truncating to 2048\n", | |
1937 | - s->manufact.len); | |
1937 | + cd_dbg(CD_WARNING, "Received invalid manufacture info length (%d): truncating to 2048\n", | |
1938 | + s->manufact.len); | |
1938 | 1939 | s->manufact.len = 2048; |
1939 | 1940 | } |
1940 | 1941 | memcpy(s->manufact.value, &buf[4], s->manufact.len); |
... | ... | @@ -1965,8 +1966,8 @@ |
1965 | 1966 | return dvd_read_manufact(cdi, s, cgc); |
1966 | 1967 | |
1967 | 1968 | default: |
1968 | - cdinfo(CD_WARNING, ": Invalid DVD structure read requested (%d)\n", | |
1969 | - s->type); | |
1969 | + cd_dbg(CD_WARNING, ": Invalid DVD structure read requested (%d)\n", | |
1970 | + s->type); | |
1970 | 1971 | return -EINVAL; |
1971 | 1972 | } |
1972 | 1973 | } |
... | ... | @@ -2255,7 +2256,7 @@ |
2255 | 2256 | u8 requested_format; |
2256 | 2257 | int ret; |
2257 | 2258 | |
2258 | - cdinfo(CD_DO_IOCTL, "entering CDROMMULTISESSION\n"); | |
2259 | + cd_dbg(CD_DO_IOCTL, "entering CDROMMULTISESSION\n"); | |
2259 | 2260 | |
2260 | 2261 | if (!(cdi->ops->capability & CDC_MULTI_SESSION)) |
2261 | 2262 | return -ENOSYS; |
2262 | 2263 | |
... | ... | @@ -2277,13 +2278,13 @@ |
2277 | 2278 | if (copy_to_user(argp, &ms_info, sizeof(ms_info))) |
2278 | 2279 | return -EFAULT; |
2279 | 2280 | |
2280 | - cdinfo(CD_DO_IOCTL, "CDROMMULTISESSION successful\n"); | |
2281 | + cd_dbg(CD_DO_IOCTL, "CDROMMULTISESSION successful\n"); | |
2281 | 2282 | return 0; |
2282 | 2283 | } |
2283 | 2284 | |
2284 | 2285 | static int cdrom_ioctl_eject(struct cdrom_device_info *cdi) |
2285 | 2286 | { |
2286 | - cdinfo(CD_DO_IOCTL, "entering CDROMEJECT\n"); | |
2287 | + cd_dbg(CD_DO_IOCTL, "entering CDROMEJECT\n"); | |
2287 | 2288 | |
2288 | 2289 | if (!CDROM_CAN(CDC_OPEN_TRAY)) |
2289 | 2290 | return -ENOSYS; |
... | ... | @@ -2300,7 +2301,7 @@ |
2300 | 2301 | |
2301 | 2302 | static int cdrom_ioctl_closetray(struct cdrom_device_info *cdi) |
2302 | 2303 | { |
2303 | - cdinfo(CD_DO_IOCTL, "entering CDROMCLOSETRAY\n"); | |
2304 | + cd_dbg(CD_DO_IOCTL, "entering CDROMCLOSETRAY\n"); | |
2304 | 2305 | |
2305 | 2306 | if (!CDROM_CAN(CDC_CLOSE_TRAY)) |
2306 | 2307 | return -ENOSYS; |
... | ... | @@ -2310,7 +2311,7 @@ |
2310 | 2311 | static int cdrom_ioctl_eject_sw(struct cdrom_device_info *cdi, |
2311 | 2312 | unsigned long arg) |
2312 | 2313 | { |
2313 | - cdinfo(CD_DO_IOCTL, "entering CDROMEJECT_SW\n"); | |
2314 | + cd_dbg(CD_DO_IOCTL, "entering CDROMEJECT_SW\n"); | |
2314 | 2315 | |
2315 | 2316 | if (!CDROM_CAN(CDC_OPEN_TRAY)) |
2316 | 2317 | return -ENOSYS; |
... | ... | @@ -2329,7 +2330,7 @@ |
2329 | 2330 | struct cdrom_changer_info *info; |
2330 | 2331 | int ret; |
2331 | 2332 | |
2332 | - cdinfo(CD_DO_IOCTL, "entering CDROM_MEDIA_CHANGED\n"); | |
2333 | + cd_dbg(CD_DO_IOCTL, "entering CDROM_MEDIA_CHANGED\n"); | |
2333 | 2334 | |
2334 | 2335 | if (!CDROM_CAN(CDC_MEDIA_CHANGED)) |
2335 | 2336 | return -ENOSYS; |
... | ... | @@ -2355,7 +2356,7 @@ |
2355 | 2356 | static int cdrom_ioctl_set_options(struct cdrom_device_info *cdi, |
2356 | 2357 | unsigned long arg) |
2357 | 2358 | { |
2358 | - cdinfo(CD_DO_IOCTL, "entering CDROM_SET_OPTIONS\n"); | |
2359 | + cd_dbg(CD_DO_IOCTL, "entering CDROM_SET_OPTIONS\n"); | |
2359 | 2360 | |
2360 | 2361 | /* |
2361 | 2362 | * Options need to be in sync with capability. |
... | ... | @@ -2383,7 +2384,7 @@ |
2383 | 2384 | static int cdrom_ioctl_clear_options(struct cdrom_device_info *cdi, |
2384 | 2385 | unsigned long arg) |
2385 | 2386 | { |
2386 | - cdinfo(CD_DO_IOCTL, "entering CDROM_CLEAR_OPTIONS\n"); | |
2387 | + cd_dbg(CD_DO_IOCTL, "entering CDROM_CLEAR_OPTIONS\n"); | |
2387 | 2388 | |
2388 | 2389 | cdi->options &= ~(int) arg; |
2389 | 2390 | return cdi->options; |
... | ... | @@ -2392,7 +2393,7 @@ |
2392 | 2393 | static int cdrom_ioctl_select_speed(struct cdrom_device_info *cdi, |
2393 | 2394 | unsigned long arg) |
2394 | 2395 | { |
2395 | - cdinfo(CD_DO_IOCTL, "entering CDROM_SELECT_SPEED\n"); | |
2396 | + cd_dbg(CD_DO_IOCTL, "entering CDROM_SELECT_SPEED\n"); | |
2396 | 2397 | |
2397 | 2398 | if (!CDROM_CAN(CDC_SELECT_SPEED)) |
2398 | 2399 | return -ENOSYS; |
... | ... | @@ -2402,7 +2403,7 @@ |
2402 | 2403 | static int cdrom_ioctl_select_disc(struct cdrom_device_info *cdi, |
2403 | 2404 | unsigned long arg) |
2404 | 2405 | { |
2405 | - cdinfo(CD_DO_IOCTL, "entering CDROM_SELECT_DISC\n"); | |
2406 | + cd_dbg(CD_DO_IOCTL, "entering CDROM_SELECT_DISC\n"); | |
2406 | 2407 | |
2407 | 2408 | if (!CDROM_CAN(CDC_SELECT_DISC)) |
2408 | 2409 | return -ENOSYS; |
2409 | 2410 | |
... | ... | @@ -2420,14 +2421,14 @@ |
2420 | 2421 | if (cdi->ops->select_disc) |
2421 | 2422 | return cdi->ops->select_disc(cdi, arg); |
2422 | 2423 | |
2423 | - cdinfo(CD_CHANGER, "Using generic cdrom_select_disc()\n"); | |
2424 | + cd_dbg(CD_CHANGER, "Using generic cdrom_select_disc()\n"); | |
2424 | 2425 | return cdrom_select_disc(cdi, arg); |
2425 | 2426 | } |
2426 | 2427 | |
2427 | 2428 | static int cdrom_ioctl_reset(struct cdrom_device_info *cdi, |
2428 | 2429 | struct block_device *bdev) |
2429 | 2430 | { |
2430 | - cdinfo(CD_DO_IOCTL, "entering CDROM_RESET\n"); | |
2431 | + cd_dbg(CD_DO_IOCTL, "entering CDROM_RESET\n"); | |
2431 | 2432 | |
2432 | 2433 | if (!capable(CAP_SYS_ADMIN)) |
2433 | 2434 | return -EACCES; |
... | ... | @@ -2440,7 +2441,7 @@ |
2440 | 2441 | static int cdrom_ioctl_lock_door(struct cdrom_device_info *cdi, |
2441 | 2442 | unsigned long arg) |
2442 | 2443 | { |
2443 | - cdinfo(CD_DO_IOCTL, "%socking door.\n", arg ? "L" : "Unl"); | |
2444 | + cd_dbg(CD_DO_IOCTL, "%socking door\n", arg ? "L" : "Unl"); | |
2444 | 2445 | |
2445 | 2446 | if (!CDROM_CAN(CDC_LOCK)) |
2446 | 2447 | return -EDRIVE_CANT_DO_THIS; |
... | ... | @@ -2459,7 +2460,7 @@ |
2459 | 2460 | static int cdrom_ioctl_debug(struct cdrom_device_info *cdi, |
2460 | 2461 | unsigned long arg) |
2461 | 2462 | { |
2462 | - cdinfo(CD_DO_IOCTL, "%sabling debug.\n", arg ? "En" : "Dis"); | |
2463 | + cd_dbg(CD_DO_IOCTL, "%sabling debug\n", arg ? "En" : "Dis"); | |
2463 | 2464 | |
2464 | 2465 | if (!capable(CAP_SYS_ADMIN)) |
2465 | 2466 | return -EACCES; |
... | ... | @@ -2469,7 +2470,7 @@ |
2469 | 2470 | |
2470 | 2471 | static int cdrom_ioctl_get_capability(struct cdrom_device_info *cdi) |
2471 | 2472 | { |
2472 | - cdinfo(CD_DO_IOCTL, "entering CDROM_GET_CAPABILITY\n"); | |
2473 | + cd_dbg(CD_DO_IOCTL, "entering CDROM_GET_CAPABILITY\n"); | |
2473 | 2474 | return (cdi->ops->capability & ~cdi->mask); |
2474 | 2475 | } |
2475 | 2476 | |
... | ... | @@ -2485,7 +2486,7 @@ |
2485 | 2486 | struct cdrom_mcn mcn; |
2486 | 2487 | int ret; |
2487 | 2488 | |
2488 | - cdinfo(CD_DO_IOCTL, "entering CDROM_GET_MCN\n"); | |
2489 | + cd_dbg(CD_DO_IOCTL, "entering CDROM_GET_MCN\n"); | |
2489 | 2490 | |
2490 | 2491 | if (!(cdi->ops->capability & CDC_MCN)) |
2491 | 2492 | return -ENOSYS; |
2492 | 2493 | |
... | ... | @@ -2495,14 +2496,14 @@ |
2495 | 2496 | |
2496 | 2497 | if (copy_to_user(argp, &mcn, sizeof(mcn))) |
2497 | 2498 | return -EFAULT; |
2498 | - cdinfo(CD_DO_IOCTL, "CDROM_GET_MCN successful\n"); | |
2499 | + cd_dbg(CD_DO_IOCTL, "CDROM_GET_MCN successful\n"); | |
2499 | 2500 | return 0; |
2500 | 2501 | } |
2501 | 2502 | |
2502 | 2503 | static int cdrom_ioctl_drive_status(struct cdrom_device_info *cdi, |
2503 | 2504 | unsigned long arg) |
2504 | 2505 | { |
2505 | - cdinfo(CD_DO_IOCTL, "entering CDROM_DRIVE_STATUS\n"); | |
2506 | + cd_dbg(CD_DO_IOCTL, "entering CDROM_DRIVE_STATUS\n"); | |
2506 | 2507 | |
2507 | 2508 | if (!(cdi->ops->capability & CDC_DRIVE_STATUS)) |
2508 | 2509 | return -ENOSYS; |
... | ... | @@ -2535,7 +2536,7 @@ |
2535 | 2536 | { |
2536 | 2537 | tracktype tracks; |
2537 | 2538 | |
2538 | - cdinfo(CD_DO_IOCTL, "entering CDROM_DISC_STATUS\n"); | |
2539 | + cd_dbg(CD_DO_IOCTL, "entering CDROM_DISC_STATUS\n"); | |
2539 | 2540 | |
2540 | 2541 | cdrom_count_tracks(cdi, &tracks); |
2541 | 2542 | if (tracks.error) |
2542 | 2543 | |
... | ... | @@ -2557,13 +2558,13 @@ |
2557 | 2558 | return CDS_DATA_1; |
2558 | 2559 | /* Policy mode off */ |
2559 | 2560 | |
2560 | - cdinfo(CD_WARNING,"This disc doesn't have any tracks I recognize!\n"); | |
2561 | + cd_dbg(CD_WARNING, "This disc doesn't have any tracks I recognize!\n"); | |
2561 | 2562 | return CDS_NO_INFO; |
2562 | 2563 | } |
2563 | 2564 | |
2564 | 2565 | static int cdrom_ioctl_changer_nslots(struct cdrom_device_info *cdi) |
2565 | 2566 | { |
2566 | - cdinfo(CD_DO_IOCTL, "entering CDROM_CHANGER_NSLOTS\n"); | |
2567 | + cd_dbg(CD_DO_IOCTL, "entering CDROM_CHANGER_NSLOTS\n"); | |
2567 | 2568 | return cdi->capacity; |
2568 | 2569 | } |
2569 | 2570 | |
... | ... | @@ -2574,7 +2575,7 @@ |
2574 | 2575 | u8 requested, back; |
2575 | 2576 | int ret; |
2576 | 2577 | |
2577 | - /* cdinfo(CD_DO_IOCTL,"entering CDROMSUBCHNL\n");*/ | |
2578 | + /* cd_dbg(CD_DO_IOCTL,"entering CDROMSUBCHNL\n");*/ | |
2578 | 2579 | |
2579 | 2580 | if (copy_from_user(&q, argp, sizeof(q))) |
2580 | 2581 | return -EFAULT; |
... | ... | @@ -2594,7 +2595,7 @@ |
2594 | 2595 | |
2595 | 2596 | if (copy_to_user(argp, &q, sizeof(q))) |
2596 | 2597 | return -EFAULT; |
2597 | - /* cdinfo(CD_DO_IOCTL, "CDROMSUBCHNL successful\n"); */ | |
2598 | + /* cd_dbg(CD_DO_IOCTL, "CDROMSUBCHNL successful\n"); */ | |
2598 | 2599 | return 0; |
2599 | 2600 | } |
2600 | 2601 | |
... | ... | @@ -2604,7 +2605,7 @@ |
2604 | 2605 | struct cdrom_tochdr header; |
2605 | 2606 | int ret; |
2606 | 2607 | |
2607 | - /* cdinfo(CD_DO_IOCTL, "entering CDROMREADTOCHDR\n"); */ | |
2608 | + /* cd_dbg(CD_DO_IOCTL, "entering CDROMREADTOCHDR\n"); */ | |
2608 | 2609 | |
2609 | 2610 | if (copy_from_user(&header, argp, sizeof(header))) |
2610 | 2611 | return -EFAULT; |
... | ... | @@ -2615,7 +2616,7 @@ |
2615 | 2616 | |
2616 | 2617 | if (copy_to_user(argp, &header, sizeof(header))) |
2617 | 2618 | return -EFAULT; |
2618 | - /* cdinfo(CD_DO_IOCTL, "CDROMREADTOCHDR successful\n"); */ | |
2619 | + /* cd_dbg(CD_DO_IOCTL, "CDROMREADTOCHDR successful\n"); */ | |
2619 | 2620 | return 0; |
2620 | 2621 | } |
2621 | 2622 | |
... | ... | @@ -2626,7 +2627,7 @@ |
2626 | 2627 | u8 requested_format; |
2627 | 2628 | int ret; |
2628 | 2629 | |
2629 | - /* cdinfo(CD_DO_IOCTL, "entering CDROMREADTOCENTRY\n"); */ | |
2630 | + /* cd_dbg(CD_DO_IOCTL, "entering CDROMREADTOCENTRY\n"); */ | |
2630 | 2631 | |
2631 | 2632 | if (copy_from_user(&entry, argp, sizeof(entry))) |
2632 | 2633 | return -EFAULT; |
... | ... | @@ -2643,7 +2644,7 @@ |
2643 | 2644 | |
2644 | 2645 | if (copy_to_user(argp, &entry, sizeof(entry))) |
2645 | 2646 | return -EFAULT; |
2646 | - /* cdinfo(CD_DO_IOCTL, "CDROMREADTOCENTRY successful\n"); */ | |
2647 | + /* cd_dbg(CD_DO_IOCTL, "CDROMREADTOCENTRY successful\n"); */ | |
2647 | 2648 | return 0; |
2648 | 2649 | } |
2649 | 2650 | |
... | ... | @@ -2652,7 +2653,7 @@ |
2652 | 2653 | { |
2653 | 2654 | struct cdrom_msf msf; |
2654 | 2655 | |
2655 | - cdinfo(CD_DO_IOCTL, "entering CDROMPLAYMSF\n"); | |
2656 | + cd_dbg(CD_DO_IOCTL, "entering CDROMPLAYMSF\n"); | |
2656 | 2657 | |
2657 | 2658 | if (!CDROM_CAN(CDC_PLAY_AUDIO)) |
2658 | 2659 | return -ENOSYS; |
... | ... | @@ -2667,7 +2668,7 @@ |
2667 | 2668 | struct cdrom_ti ti; |
2668 | 2669 | int ret; |
2669 | 2670 | |
2670 | - cdinfo(CD_DO_IOCTL, "entering CDROMPLAYTRKIND\n"); | |
2671 | + cd_dbg(CD_DO_IOCTL, "entering CDROMPLAYTRKIND\n"); | |
2671 | 2672 | |
2672 | 2673 | if (!CDROM_CAN(CDC_PLAY_AUDIO)) |
2673 | 2674 | return -ENOSYS; |
... | ... | @@ -2684,7 +2685,7 @@ |
2684 | 2685 | { |
2685 | 2686 | struct cdrom_volctrl volume; |
2686 | 2687 | |
2687 | - cdinfo(CD_DO_IOCTL, "entering CDROMVOLCTRL\n"); | |
2688 | + cd_dbg(CD_DO_IOCTL, "entering CDROMVOLCTRL\n"); | |
2688 | 2689 | |
2689 | 2690 | if (!CDROM_CAN(CDC_PLAY_AUDIO)) |
2690 | 2691 | return -ENOSYS; |
... | ... | @@ -2699,7 +2700,7 @@ |
2699 | 2700 | struct cdrom_volctrl volume; |
2700 | 2701 | int ret; |
2701 | 2702 | |
2702 | - cdinfo(CD_DO_IOCTL, "entering CDROMVOLREAD\n"); | |
2703 | + cd_dbg(CD_DO_IOCTL, "entering CDROMVOLREAD\n"); | |
2703 | 2704 | |
2704 | 2705 | if (!CDROM_CAN(CDC_PLAY_AUDIO)) |
2705 | 2706 | return -ENOSYS; |
... | ... | @@ -2718,7 +2719,7 @@ |
2718 | 2719 | { |
2719 | 2720 | int ret; |
2720 | 2721 | |
2721 | - cdinfo(CD_DO_IOCTL, "doing audio ioctl (start/stop/pause/resume)\n"); | |
2722 | + cd_dbg(CD_DO_IOCTL, "doing audio ioctl (start/stop/pause/resume)\n"); | |
2722 | 2723 | |
2723 | 2724 | if (!CDROM_CAN(CDC_PLAY_AUDIO)) |
2724 | 2725 | return -ENOSYS; |
... | ... | @@ -2796,7 +2797,7 @@ |
2796 | 2797 | } |
2797 | 2798 | |
2798 | 2799 | /* |
2799 | - * Note: most of the cdinfo() calls are commented out here, | |
2800 | + * Note: most of the cd_dbg() calls are commented out here, | |
2800 | 2801 | * because they fill up the sys log when CD players poll |
2801 | 2802 | * the drive. |
2802 | 2803 | */ |
... | ... | @@ -2955,7 +2956,7 @@ |
2955 | 2956 | sanitize_format(&q.cdsc_absaddr, &back, requested); |
2956 | 2957 | sanitize_format(&q.cdsc_reladdr, &q.cdsc_format, requested); |
2957 | 2958 | IOCTL_OUT(arg, struct cdrom_subchnl, q); |
2958 | - /* cdinfo(CD_DO_IOCTL, "CDROMSUBCHNL successful\n"); */ | |
2959 | + /* cd_dbg(CD_DO_IOCTL, "CDROMSUBCHNL successful\n"); */ | |
2959 | 2960 | return 0; |
2960 | 2961 | } |
2961 | 2962 | |
... | ... | @@ -2965,7 +2966,7 @@ |
2965 | 2966 | { |
2966 | 2967 | struct cdrom_device_ops *cdo = cdi->ops; |
2967 | 2968 | struct cdrom_msf msf; |
2968 | - cdinfo(CD_DO_IOCTL, "entering CDROMPLAYMSF\n"); | |
2969 | + cd_dbg(CD_DO_IOCTL, "entering CDROMPLAYMSF\n"); | |
2969 | 2970 | IOCTL_IN(arg, struct cdrom_msf, msf); |
2970 | 2971 | cgc->cmd[0] = GPCMD_PLAY_AUDIO_MSF; |
2971 | 2972 | cgc->cmd[3] = msf.cdmsf_min0; |
... | ... | @@ -2984,7 +2985,7 @@ |
2984 | 2985 | { |
2985 | 2986 | struct cdrom_device_ops *cdo = cdi->ops; |
2986 | 2987 | struct cdrom_blk blk; |
2987 | - cdinfo(CD_DO_IOCTL, "entering CDROMPLAYBLK\n"); | |
2988 | + cd_dbg(CD_DO_IOCTL, "entering CDROMPLAYBLK\n"); | |
2988 | 2989 | IOCTL_IN(arg, struct cdrom_blk, blk); |
2989 | 2990 | cgc->cmd[0] = GPCMD_PLAY_AUDIO_10; |
2990 | 2991 | cgc->cmd[2] = (blk.from >> 24) & 0xff; |
... | ... | @@ -3008,7 +3009,7 @@ |
3008 | 3009 | unsigned short offset; |
3009 | 3010 | int ret; |
3010 | 3011 | |
3011 | - cdinfo(CD_DO_IOCTL, "entering CDROMVOLUME\n"); | |
3012 | + cd_dbg(CD_DO_IOCTL, "entering CDROMVOLUME\n"); | |
3012 | 3013 | |
3013 | 3014 | IOCTL_IN(arg, struct cdrom_volctrl, volctrl); |
3014 | 3015 | |
... | ... | @@ -3073,7 +3074,7 @@ |
3073 | 3074 | int cmd) |
3074 | 3075 | { |
3075 | 3076 | struct cdrom_device_ops *cdo = cdi->ops; |
3076 | - cdinfo(CD_DO_IOCTL, "entering CDROMSTART/CDROMSTOP\n"); | |
3077 | + cd_dbg(CD_DO_IOCTL, "entering CDROMSTART/CDROMSTOP\n"); | |
3077 | 3078 | cgc->cmd[0] = GPCMD_START_STOP_UNIT; |
3078 | 3079 | cgc->cmd[1] = 1; |
3079 | 3080 | cgc->cmd[4] = (cmd == CDROMSTART) ? 1 : 0; |
... | ... | @@ -3086,7 +3087,7 @@ |
3086 | 3087 | int cmd) |
3087 | 3088 | { |
3088 | 3089 | struct cdrom_device_ops *cdo = cdi->ops; |
3089 | - cdinfo(CD_DO_IOCTL, "entering CDROMPAUSE/CDROMRESUME\n"); | |
3090 | + cd_dbg(CD_DO_IOCTL, "entering CDROMPAUSE/CDROMRESUME\n"); | |
3090 | 3091 | cgc->cmd[0] = GPCMD_PAUSE_RESUME; |
3091 | 3092 | cgc->cmd[8] = (cmd == CDROMRESUME) ? 1 : 0; |
3092 | 3093 | cgc->data_direction = CGC_DATA_NONE; |
... | ... | @@ -3108,7 +3109,7 @@ |
3108 | 3109 | if (!s) |
3109 | 3110 | return -ENOMEM; |
3110 | 3111 | |
3111 | - cdinfo(CD_DO_IOCTL, "entering DVD_READ_STRUCT\n"); | |
3112 | + cd_dbg(CD_DO_IOCTL, "entering DVD_READ_STRUCT\n"); | |
3112 | 3113 | if (copy_from_user(s, arg, size)) { |
3113 | 3114 | kfree(s); |
3114 | 3115 | return -EFAULT; |
... | ... | @@ -3132,7 +3133,7 @@ |
3132 | 3133 | dvd_authinfo ai; |
3133 | 3134 | if (!CDROM_CAN(CDC_DVD)) |
3134 | 3135 | return -ENOSYS; |
3135 | - cdinfo(CD_DO_IOCTL, "entering DVD_AUTH\n"); | |
3136 | + cd_dbg(CD_DO_IOCTL, "entering DVD_AUTH\n"); | |
3136 | 3137 | IOCTL_IN(arg, dvd_authinfo, ai); |
3137 | 3138 | ret = dvd_do_auth(cdi, &ai); |
3138 | 3139 | if (ret) |
... | ... | @@ -3146,7 +3147,7 @@ |
3146 | 3147 | { |
3147 | 3148 | int ret; |
3148 | 3149 | long next = 0; |
3149 | - cdinfo(CD_DO_IOCTL, "entering CDROM_NEXT_WRITABLE\n"); | |
3150 | + cd_dbg(CD_DO_IOCTL, "entering CDROM_NEXT_WRITABLE\n"); | |
3150 | 3151 | ret = cdrom_get_next_writable(cdi, &next); |
3151 | 3152 | if (ret) |
3152 | 3153 | return ret; |
... | ... | @@ -3159,7 +3160,7 @@ |
3159 | 3160 | { |
3160 | 3161 | int ret; |
3161 | 3162 | long last = 0; |
3162 | - cdinfo(CD_DO_IOCTL, "entering CDROM_LAST_WRITTEN\n"); | |
3163 | + cd_dbg(CD_DO_IOCTL, "entering CDROM_LAST_WRITTEN\n"); | |
3163 | 3164 | ret = cdrom_get_last_written(cdi, &last); |
3164 | 3165 | if (ret) |
3165 | 3166 | return ret; |