.. | .. |
---|
| 1 | +/* SPDX-License-Identifier: GPL-2.0-or-later */ |
---|
1 | 2 | /* -*- mode: c; c-basic-offset: 8; -*- |
---|
2 | 3 | * vim: noexpandtab sw=8 ts=8 sts=0: |
---|
3 | 4 | * |
---|
4 | 5 | * dlmcommon.h |
---|
5 | 6 | * |
---|
6 | 7 | * Copyright (C) 2004 Oracle. All rights reserved. |
---|
7 | | - * |
---|
8 | | - * This program is free software; you can redistribute it and/or |
---|
9 | | - * modify it under the terms of the GNU General Public |
---|
10 | | - * License as published by the Free Software Foundation; either |
---|
11 | | - * version 2 of the License, or (at your option) any later version. |
---|
12 | | - * |
---|
13 | | - * This program is distributed in the hope that it will be useful, |
---|
14 | | - * but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
15 | | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
---|
16 | | - * General Public License for more details. |
---|
17 | | - * |
---|
18 | | - * You should have received a copy of the GNU General Public |
---|
19 | | - * License along with this program; if not, write to the |
---|
20 | | - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
---|
21 | | - * Boston, MA 021110-1307, USA. |
---|
22 | | - * |
---|
23 | 8 | */ |
---|
24 | 9 | |
---|
25 | 10 | #ifndef DLMCOMMON_H |
---|
.. | .. |
---|
157 | 142 | atomic_t res_tot_count; |
---|
158 | 143 | atomic_t res_cur_count; |
---|
159 | 144 | |
---|
160 | | - struct dlm_debug_ctxt *dlm_debug_ctxt; |
---|
161 | 145 | struct dentry *dlm_debugfs_subroot; |
---|
162 | 146 | |
---|
163 | 147 | /* NOTE: Next three are protected by dlm_domain_lock */ |
---|
.. | .. |
---|
580 | 564 | // 48 bytes |
---|
581 | 565 | u8 lvb[DLM_LVB_LEN]; |
---|
582 | 566 | // 112 bytes |
---|
583 | | - struct dlm_migratable_lock ml[0]; // 16 bytes each, begins at byte 112 |
---|
| 567 | + struct dlm_migratable_lock ml[]; // 16 bytes each, begins at byte 112 |
---|
584 | 568 | }; |
---|
585 | 569 | #define DLM_MIG_LOCKRES_MAX_LEN \ |
---|
586 | 570 | (sizeof(struct dlm_migratable_lockres) + \ |
---|
.. | .. |
---|
617 | 601 | |
---|
618 | 602 | u8 name[O2NM_MAX_NAME_LEN]; |
---|
619 | 603 | |
---|
620 | | - s8 lvb[0]; |
---|
| 604 | + s8 lvb[]; |
---|
621 | 605 | }; |
---|
622 | 606 | #define DLM_CONVERT_LOCK_MAX_LEN (sizeof(struct dlm_convert_lock)+DLM_LVB_LEN) |
---|
623 | 607 | |
---|
.. | .. |
---|
632 | 616 | |
---|
633 | 617 | u8 name[O2NM_MAX_NAME_LEN]; |
---|
634 | 618 | |
---|
635 | | - s8 lvb[0]; |
---|
| 619 | + s8 lvb[]; |
---|
636 | 620 | }; |
---|
637 | 621 | #define DLM_UNLOCK_LOCK_MAX_LEN (sizeof(struct dlm_unlock_lock)+DLM_LVB_LEN) |
---|
638 | 622 | |
---|
.. | .. |
---|
648 | 632 | |
---|
649 | 633 | u8 name[O2NM_MAX_NAME_LEN]; |
---|
650 | 634 | |
---|
651 | | - s8 lvb[0]; |
---|
| 635 | + s8 lvb[]; |
---|
652 | 636 | }; |
---|
653 | 637 | #define DLM_PROXY_AST_MAX_LEN (sizeof(struct dlm_proxy_ast)+DLM_LVB_LEN) |
---|
654 | 638 | |
---|
.. | .. |
---|
703 | 687 | __be16 pad1; |
---|
704 | 688 | __be32 pad2; |
---|
705 | 689 | }; |
---|
706 | | - |
---|
707 | | - |
---|
708 | | -#define BITS_PER_BYTE 8 |
---|
709 | | -#define BITS_TO_BYTES(bits) (((bits)+BITS_PER_BYTE-1)/BITS_PER_BYTE) |
---|
710 | 690 | |
---|
711 | 691 | struct dlm_query_join_request |
---|
712 | 692 | { |
---|