Lines Matching refs:monbuf
99 struct mon_buf *monbuf; in monwrite_new_hdr() local
106 monbuf = NULL; in monwrite_new_hdr()
108 monbuf = monwrite_find_hdr(monpriv, monhdr); in monwrite_new_hdr()
109 if (monbuf) { in monwrite_new_hdr()
111 monhdr->datalen = monbuf->hdr.datalen; in monwrite_new_hdr()
112 rc = monwrite_diag(monhdr, monbuf->data, in monwrite_new_hdr()
114 list_del(&monbuf->list); in monwrite_new_hdr()
116 kfree(monbuf->data); in monwrite_new_hdr()
117 kfree(monbuf); in monwrite_new_hdr()
118 monbuf = NULL; in monwrite_new_hdr()
123 monbuf = kzalloc(sizeof(struct mon_buf), GFP_KERNEL); in monwrite_new_hdr()
124 if (!monbuf) in monwrite_new_hdr()
126 monbuf->data = kzalloc(monhdr->datalen, in monwrite_new_hdr()
128 if (!monbuf->data) { in monwrite_new_hdr()
129 kfree(monbuf); in monwrite_new_hdr()
132 monbuf->hdr = *monhdr; in monwrite_new_hdr()
133 list_add_tail(&monbuf->list, &monpriv->list); in monwrite_new_hdr()
137 monpriv->current_buf = monbuf; in monwrite_new_hdr()
144 struct mon_buf *monbuf = monpriv->current_buf; in monwrite_new_data() local
149 if (!monbuf->diag_done) { in monwrite_new_data()
150 rc = monwrite_diag(monhdr, monbuf->data, in monwrite_new_data()
152 monbuf->diag_done = 1; in monwrite_new_data()
156 if (!monbuf->diag_done) { in monwrite_new_data()
157 rc = monwrite_diag(monhdr, monbuf->data, in monwrite_new_data()
159 monbuf->diag_done = 1; in monwrite_new_data()
163 rc = monwrite_diag(monhdr, monbuf->data, in monwrite_new_data()
293 struct mon_buf *monbuf; in monwriter_freeze() local
296 list_for_each_entry(monbuf, &monpriv->list, list) { in monwriter_freeze()
297 if (monbuf->hdr.mon_function != MONWRITE_GEN_EVENT) in monwriter_freeze()
298 monwrite_diag(&monbuf->hdr, monbuf->data, in monwriter_freeze()
308 struct mon_buf *monbuf; in monwriter_restore() local
311 list_for_each_entry(monbuf, &monpriv->list, list) { in monwriter_restore()
312 if (monbuf->hdr.mon_function == MONWRITE_START_INTERVAL) in monwriter_restore()
313 monwrite_diag(&monbuf->hdr, monbuf->data, in monwriter_restore()
315 if (monbuf->hdr.mon_function == MONWRITE_START_CONFIG) in monwriter_restore()
316 monwrite_diag(&monbuf->hdr, monbuf->data, in monwriter_restore()