hc
2024-01-03 2f7c68cb55ecb7331f2381deb497c27155f32faf
kernel/arch/powerpc/platforms/pseries/eeh_pseries.c
....@@ -846,18 +846,8 @@
846846 return -EINVAL;
847847 }
848848
849
- /* Initialize error log lock and size */
850
- spin_lock_init(&slot_errbuf_lock);
851
- eeh_error_buf_size = rtas_token("rtas-error-log-max");
852
- if (eeh_error_buf_size == RTAS_UNKNOWN_SERVICE) {
853
- pr_info("%s: unknown EEH error log size\n",
854
- __func__);
855
- eeh_error_buf_size = 1024;
856
- } else if (eeh_error_buf_size > RTAS_ERROR_LOG_MAX) {
857
- pr_info("%s: EEH error log size %d exceeds the maximal %d\n",
858
- __func__, eeh_error_buf_size, RTAS_ERROR_LOG_MAX);
859
- eeh_error_buf_size = RTAS_ERROR_LOG_MAX;
860
- }
849
+ /* Initialize error log size */
850
+ eeh_error_buf_size = rtas_get_error_log_max();
861851
862852 /* Set EEH probe mode */
863853 eeh_add_flag(EEH_PROBE_MODE_DEVTREE | EEH_ENABLE_IO_FOR_LOG);