Lines Matching +full:scan +full:- +full:count

1 // SPDX-License-Identifier: GPL-2.0-or-later
40 static int surveillance_timeout = -1;
104 * --------------------------------------------------------
105 * 0-7 (8) : rtas_error_log
106 * 8-47 (40) : extended info
107 * 48-51 (4) : vendor id
108 * 52-1023 (vendor specific) : location code and debug data
119 printk(RTAS_DEBUG "%d -------- %s begin --------\n", in printk_log_rtas()
140 if (j == (perline-1)) in printk_log_rtas()
146 printk(RTAS_DEBUG "%d -------- %s end ----------\n", in printk_log_rtas()
210 /* get length and increase count */ in pSeries_log_error()
300 size_t count, loff_t *ppos) in rtas_log_read() argument
307 if (!buf || count < rtas_error_log_buffer_max) in rtas_log_read()
308 return -EINVAL; in rtas_log_read()
310 count = rtas_error_log_buffer_max; in rtas_log_read()
312 if (!access_ok(buf, count)) in rtas_log_read()
313 return -EFAULT; in rtas_log_read()
315 tmp = kmalloc(count, GFP_KERNEL); in rtas_log_read()
317 return -ENOMEM; in rtas_log_read()
323 if (file->f_flags & O_NONBLOCK) { in rtas_log_read()
325 error = -EAGAIN; in rtas_log_read()
331 error = -ENODATA; in rtas_log_read()
346 memcpy(tmp, &rtas_log_buf[offset], count); in rtas_log_read()
349 rtas_log_size -= 1; in rtas_log_read()
352 error = copy_to_user(buf, tmp, count) ? -EFAULT : count; in rtas_log_read()
383 if (error == -EINVAL) { in enable_surveillance()
389 return -1; in enable_surveillance()
400 if (error == -1) { in do_event_scan()
401 printk(KERN_ERR "event-scan failed\n"); in do_event_scan()
421 * we call event-scan too quickly.
443 if (surveillance_timeout != -1) { in rtas_event_scan()
494 /* Cancel the rtas event scan work */
511 printk(KERN_INFO "rtasd: No event-scan on system\n"); in rtas_event_scan_init()
512 return -ENODEV; in rtas_event_scan_init()
515 err = of_property_read_u32(rtas.dev, "rtas-event-scan-rate", &rtas_event_scan_rate); in rtas_event_scan_init()
517 printk(KERN_ERR "rtasd: no rtas-event-scan-rate on system\n"); in rtas_event_scan_init()
518 return -ENODEV; in rtas_event_scan_init()
522 /* Broken firmware: take a rate of zero to mean don't scan */ in rtas_event_scan_init()
523 printk(KERN_DEBUG "rtasd: scan rate is 0, not scanning\n"); in rtas_event_scan_init()
535 return -ENOMEM; in rtas_event_scan_init()
552 return -ENODEV; in rtas_init()