• Home
  • Raw
  • Download

Lines Matching refs:data

610 static int crc32_threadfn(void *data)  in crc32_threadfn()  argument
612 struct crc_data *d = data; in crc32_threadfn()
654 static int lzo_compress_threadfn(void *data) in lzo_compress_threadfn() argument
656 struct cmp_data *d = data; in lzo_compress_threadfn()
699 struct cmp_data *data = NULL; in save_image_lzo() local
718 data = vzalloc(array_size(nr_threads, sizeof(*data))); in save_image_lzo()
719 if (!data) { in save_image_lzo()
736 init_waitqueue_head(&data[thr].go); in save_image_lzo()
737 init_waitqueue_head(&data[thr].done); in save_image_lzo()
739 data[thr].thr = kthread_run(lzo_compress_threadfn, in save_image_lzo()
740 &data[thr], in save_image_lzo()
742 if (IS_ERR(data[thr].thr)) { in save_image_lzo()
743 data[thr].thr = NULL; in save_image_lzo()
759 crc->unc[thr] = data[thr].unc; in save_image_lzo()
760 crc->unc_len[thr] = &data[thr].unc_len; in save_image_lzo()
795 memcpy(data[thr].unc + off, in save_image_lzo()
806 data[thr].unc_len = off; in save_image_lzo()
808 atomic_set_release(&data[thr].ready, 1); in save_image_lzo()
809 wake_up(&data[thr].go); in save_image_lzo()
820 wait_event(data[thr].done, in save_image_lzo()
821 atomic_read_acquire(&data[thr].stop)); in save_image_lzo()
822 atomic_set(&data[thr].stop, 0); in save_image_lzo()
824 ret = data[thr].ret; in save_image_lzo()
831 if (unlikely(!data[thr].cmp_len || in save_image_lzo()
832 data[thr].cmp_len > in save_image_lzo()
833 lzo1x_worst_compress(data[thr].unc_len))) { in save_image_lzo()
839 *(size_t *)data[thr].cmp = data[thr].cmp_len; in save_image_lzo()
850 off < LZO_HEADER + data[thr].cmp_len; in save_image_lzo()
852 memcpy(page, data[thr].cmp + off, PAGE_SIZE); in save_image_lzo()
879 if (data) { in save_image_lzo()
881 if (data[thr].thr) in save_image_lzo()
882 kthread_stop(data[thr].thr); in save_image_lzo()
883 vfree(data); in save_image_lzo()
1138 static int lzo_decompress_threadfn(void *data) in lzo_decompress_threadfn() argument
1140 struct dec_data *d = data; in lzo_decompress_threadfn()
1190 struct dec_data *data = NULL; in load_image_lzo() local
1209 data = vzalloc(array_size(nr_threads, sizeof(*data))); in load_image_lzo()
1210 if (!data) { in load_image_lzo()
1229 init_waitqueue_head(&data[thr].go); in load_image_lzo()
1230 init_waitqueue_head(&data[thr].done); in load_image_lzo()
1232 data[thr].thr = kthread_run(lzo_decompress_threadfn, in load_image_lzo()
1233 &data[thr], in load_image_lzo()
1235 if (IS_ERR(data[thr].thr)) { in load_image_lzo()
1236 data[thr].thr = NULL; in load_image_lzo()
1252 crc->unc[thr] = data[thr].unc; in load_image_lzo()
1253 crc->unc_len[thr] = &data[thr].unc_len; in load_image_lzo()
1352 data[thr].cmp_len = *(size_t *)page[pg]; in load_image_lzo()
1353 if (unlikely(!data[thr].cmp_len || in load_image_lzo()
1354 data[thr].cmp_len > in load_image_lzo()
1361 need = DIV_ROUND_UP(data[thr].cmp_len + LZO_HEADER, in load_image_lzo()
1372 off < LZO_HEADER + data[thr].cmp_len; in load_image_lzo()
1374 memcpy(data[thr].cmp + off, in load_image_lzo()
1382 atomic_set_release(&data[thr].ready, 1); in load_image_lzo()
1383 wake_up(&data[thr].go); in load_image_lzo()
1400 wait_event(data[thr].done, in load_image_lzo()
1401 atomic_read_acquire(&data[thr].stop)); in load_image_lzo()
1402 atomic_set(&data[thr].stop, 0); in load_image_lzo()
1404 ret = data[thr].ret; in load_image_lzo()
1411 if (unlikely(!data[thr].unc_len || in load_image_lzo()
1412 data[thr].unc_len > LZO_UNC_SIZE || in load_image_lzo()
1413 data[thr].unc_len & (PAGE_SIZE - 1))) { in load_image_lzo()
1420 off < data[thr].unc_len; off += PAGE_SIZE) { in load_image_lzo()
1422 data[thr].unc + off, PAGE_SIZE); in load_image_lzo()
1474 if (data) { in load_image_lzo()
1476 if (data[thr].thr) in load_image_lzo()
1477 kthread_stop(data[thr].thr); in load_image_lzo()
1478 vfree(data); in load_image_lzo()