bitext.h 631 B

12345678910111213141516171819202122232425262728
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. /*
  3. * bitext.h: Bit string operations on the sparc, specific to architecture.
  4. *
  5. * Copyright 2002 Pete Zaitcev <[email protected]>
  6. */
  7. #ifndef _SPARC_BITEXT_H
  8. #define _SPARC_BITEXT_H
  9. #include <linux/spinlock.h>
  10. struct bit_map {
  11. spinlock_t lock;
  12. unsigned long *map;
  13. int size;
  14. int used;
  15. int last_off;
  16. int last_size;
  17. int first_free;
  18. int num_colors;
  19. };
  20. int bit_map_string_get(struct bit_map *t, int len, int align);
  21. void bit_map_clear(struct bit_map *t, int offset, int len);
  22. void bit_map_init(struct bit_map *t, unsigned long *map, int size);
  23. #endif /* defined(_SPARC_BITEXT_H) */