Lines Matching refs:diff
76 * Instantiate find diff functions for relevant unsigned integer sizes,
245 * @diff: The struct vmw_diff_cpy closure argument (unused).
250 void vmw_memcpy(struct vmw_diff_cpy *diff, u8 *dest, const u8 *src, size_t n)
259 * @diff: The struct vmw_diff_cpy used to track the modified bounding box.
260 * @diff_offs: The offset from @diff->line_offset where the difference was
263 static void vmw_adjust_rect(struct vmw_diff_cpy *diff, size_t diff_offs)
265 size_t offs = (diff_offs + diff->line_offset) / diff->cpp;
266 struct drm_rect *rect = &diff->rect;
270 rect->y1 = min_t(int, rect->y1, diff->line);
271 rect->y2 = max_t(int, rect->y2, diff->line + 1);
277 * @diff: The struct vmw_diff_cpy used to track the modified bounding box.
282 * In order to correctly track the modified content, the field @diff->line must
283 * be pre-loaded with the current line number, the field @diff->line_offset must
285 * finally the field @diff->cpp need to be preloaded with the number of bytes
292 void vmw_diff_memcpy(struct vmw_diff_cpy *diff, u8 *dest, const u8 *src,
297 if (WARN_ON_ONCE(round_down(n, diff->cpp) != n))
301 csize = vmw_find_first_diff(dest, src, n, diff->cpp);
303 vmw_adjust_rect(diff, csize);
304 byte_len = diff->cpp;
310 diff->line_offset += csize;
314 csize = vmw_find_last_diff(dest, src, n, diff->cpp);
317 vmw_adjust_rect(diff, csize);
321 diff->line_offset += n;
337 * @diff: Struct vmw_diff_cpy, in the end forwarded to the memcpy routine.
350 struct vmw_diff_cpy *diff;
366 struct vmw_diff_cpy *diff = d->diff;
416 diff->do_cpy(diff, d->dst_addr + dst_page_offset,
455 struct vmw_diff_cpy *diff)
493 d.diff = diff;
496 diff->line = j + initial_line;
497 diff->line_offset = dst_offset % dst_stride;