Lines Matching full:observed
40 /* Report as observed from console. */
45 } observed = { variable
46 .lock = __SPIN_LOCK_UNLOCKED(observed.lock),
49 /* Probe for console output: obtains observed lines of interest. */
55 spin_lock_irqsave(&observed.lock, flags); in probe_console()
56 nlines = observed.nlines; in probe_console()
65 strscpy(observed.lines[0], buf, min(len + 1, sizeof(observed.lines[0]))); in probe_console()
68 strscpy(observed.lines[nlines++], buf, min(len + 1, sizeof(observed.lines[0]))); in probe_console()
71 WRITE_ONCE(observed.nlines, nlines); /* Publish new nlines. */ in probe_console()
72 spin_unlock_irqrestore(&observed.lock, flags); in probe_console()
78 return READ_ONCE(observed.nlines) == ARRAY_SIZE(observed.lines); in report_available()
94 /* Check observed report matches information in @r. */
100 typeof(observed.lines) expect; in report_matches()
167 spin_lock_irqsave(&observed.lock, flags); in report_matches()
171 /* Finally match expected output to what we actually observed. */ in report_matches()
172 ret = strstr(observed.lines[0], expect[0]) && strstr(observed.lines[1], expect[1]); in report_matches()
174 spin_unlock_irqrestore(&observed.lock, flags); in report_matches()
810 spin_lock_irqsave(&observed.lock, flags); in test_init()
811 for (i = 0; i < ARRAY_SIZE(observed.lines); i++) in test_init()
812 observed.lines[i][0] = '\0'; in test_init()
813 observed.nlines = 0; in test_init()
814 spin_unlock_irqrestore(&observed.lock, flags); in test_init()