| 2035 | } |
| 2036 | |
| 2037 | static void |
| 2038 | raidz_restore_orig_data(raidz_map_t *rm) |
| 2039 | { |
| 2040 | for (int i = 0; i < rm->rm_nrows; i++) { |
| 2041 | raidz_row_t *rr = rm->rm_row[i]; |
| 2042 | for (int c = 0; c < rr->rr_cols; c++) { |
| 2043 | raidz_col_t *rc = &rr->rr_col[c]; |
| 2044 | if (rc->rc_need_orig_restore) { |
| 2045 | abd_copy_from_buf(rc->rc_abd, |
| 2046 | rc->rc_orig_data, rc->rc_size); |
| 2047 | rc->rc_need_orig_restore = B_FALSE; |
| 2048 | } |
| 2049 | } |
| 2050 | } |
| 2051 | } |
| 2052 | |
| 2053 | /* |
| 2054 | * returns EINVAL if reconstruction of the block will not be possible |
no test coverage detected