Home
last modified time | relevance | path

Searched refs:sb (Results 1 – 25 of 78) sorted by relevance

1234

/drivers/md/bcache/
Dsuper.c64 static const char *read_super(struct cache_sb *sb, struct block_device *bdev, in read_super() argument
77 sb->offset = le64_to_cpu(s->offset); in read_super()
78 sb->version = le64_to_cpu(s->version); in read_super()
80 memcpy(sb->magic, s->magic, 16); in read_super()
81 memcpy(sb->uuid, s->uuid, 16); in read_super()
82 memcpy(sb->set_uuid, s->set_uuid, 16); in read_super()
83 memcpy(sb->label, s->label, SB_LABEL_SIZE); in read_super()
85 sb->flags = le64_to_cpu(s->flags); in read_super()
86 sb->seq = le64_to_cpu(s->seq); in read_super()
87 sb->last_mount = le32_to_cpu(s->last_mount); in read_super()
[all …]
Djournal.c44 sector_t bucket = bucket_to_sector(ca->set, ca->sb.d[bucket_index]); in journal_read_bucket()
50 while (offset < ca->sb.bucket_size) { in journal_read_bucket()
51 reread: left = ca->sb.bucket_size - offset; in journal_read_bucket()
78 if (j->magic != jset_magic(&ca->sb)) { in journal_read_bucket()
135 offset += blocks * ca->sb.block_size; in journal_read_bucket()
136 len -= blocks * ca->sb.block_size; in journal_read_bucket()
165 pr_debug("%u journal buckets", ca->sb.njournal_buckets); in bch_journal_read()
171 for (i = 0; i < ca->sb.njournal_buckets; i++) { in bch_journal_read()
172 l = (i * 2654435769U) % ca->sb.njournal_buckets; in bch_journal_read()
187 for (l = find_first_zero_bit(bitmap, ca->sb.njournal_buckets); in bch_journal_read()
[all …]
Dsysfs.c120 BDEV_CACHE_MODE(&dc->sb)); in SHOW()
176 sysfs_print(state, states[BDEV_STATE(&dc->sb)]); in SHOW()
179 memcpy(buf, dc->sb.label, SB_LABEL_SIZE); in SHOW()
236 if ((unsigned) v != BDEV_CACHE_MODE(&dc->sb)) { in STORE()
237 SET_BDEV_CACHE_MODE(&dc->sb, v); in STORE()
245 memcpy(dc->sb.label, buf, size); in STORE()
247 dc->sb.label[size] = '\0'; in STORE()
248 if (size && dc->sb.label[size - 1] == '\n') in STORE()
249 dc->sb.label[size - 1] = '\0'; in STORE()
260 add_uevent_var(env, "CACHED_UUID=%pU", dc->sb.uuid), in STORE()
[all …]
Dalloc.c88 unsigned next = c->nbuckets * c->sb.bucket_size / 1024; in bch_rescale_priorities()
221 if (ca->fifo_last_bucket < ca->sb.first_bucket || in invalidate_buckets_fifo()
222 ca->fifo_last_bucket >= ca->sb.nbuckets) in invalidate_buckets_fifo()
223 ca->fifo_last_bucket = ca->sb.first_bucket; in invalidate_buckets_fifo()
230 if (++checked >= ca->sb.nbuckets) { in invalidate_buckets_fifo()
247 n %= (size_t) (ca->sb.nbuckets - ca->sb.first_bucket); in invalidate_buckets_random()
248 n += ca->sb.first_bucket; in invalidate_buckets_random()
255 if (++checked >= ca->sb.nbuckets / 2) { in invalidate_buckets_random()
267 switch (CACHE_REPLACEMENT(&ca->sb)) { in invalidate_buckets()
337 ca->sb.bucket_size, GFP_KERNEL, 0); in bch_allocator_thread()
[all …]
Dbcache.h295 struct cache_sb sb; member
383 struct cache_sb sb; member
483 struct cache_sb sb; member
692 #define bucket_pages(c) ((c)->sb.bucket_size / PAGE_SECTORS)
693 #define bucket_bytes(c) ((c)->sb.bucket_size << 9)
694 #define block_bytes(c) ((c)->sb.block_size << 9)
700 DIV_ROUND_UP((size_t) (c)->sb.nbuckets, prios_per_bucket(c))
714 return s & (c->sb.bucket_size - 1); in bucket_remainder()
802 for (iter = 0; ca = cs->cache[iter], iter < (cs)->sb.nr_in_set; iter++)
805 for (b = (ca)->buckets + (ca)->sb.first_bucket; \
[all …]
/drivers/mtd/
Dmtdsuper.c26 static int get_sb_mtd_compare(struct super_block *sb, void *_mtd) in get_sb_mtd_compare() argument
30 if (sb->s_mtd == mtd) { in get_sb_mtd_compare()
37 sb->s_mtd->index, sb->s_mtd->name, mtd->index, mtd->name); in get_sb_mtd_compare()
46 static int get_sb_mtd_set(struct super_block *sb, void *_mtd) in get_sb_mtd_set() argument
50 sb->s_mtd = mtd; in get_sb_mtd_set()
51 sb->s_dev = MKDEV(MTD_BLOCK_MAJOR, mtd->index); in get_sb_mtd_set()
52 sb->s_bdi = mtd->backing_dev_info; in get_sb_mtd_set()
64 struct super_block *sb; in mount_mtd_aux() local
67 sb = sget(fs_type, get_sb_mtd_compare, get_sb_mtd_set, flags, mtd); in mount_mtd_aux()
68 if (IS_ERR(sb)) in mount_mtd_aux()
[all …]
/drivers/net/wireless/brcm80211/brcmutil/
Dd11.c24 static u16 d11n_sb(enum brcmu_chan_sb sb) in d11n_sb() argument
26 switch (sb) { in d11n_sb()
55 ch->sb = BRCMU_CHAN_SB_NONE; in brcmu_d11n_encchspec()
61 0, d11n_sb(ch->sb)); in brcmu_d11n_encchspec()
88 if (ch->bw == BRCMU_CHAN_BW_20 || ch->sb == BRCMU_CHAN_SB_NONE) in brcmu_d11ac_encchspec()
89 ch->sb = BRCMU_CHAN_SB_L; in brcmu_d11ac_encchspec()
94 BRCMU_CHSPEC_D11AC_SB_SHIFT, ch->sb); in brcmu_d11ac_encchspec()
114 ch->sb = BRCMU_CHAN_SB_NONE; in brcmu_d11n_decchspec()
120 ch->sb = BRCMU_CHAN_SB_L; in brcmu_d11n_decchspec()
123 ch->sb = BRCMU_CHAN_SB_U; in brcmu_d11n_decchspec()
[all …]
/drivers/staging/lustre/lustre/obdclass/
Dobd_mount.c55 static int (*client_fill_super)(struct super_block *sb,
58 static void (*kill_super_cb)(struct super_block *sb);
74 int lustre_process_log(struct super_block *sb, char *logname, in lustre_process_log() argument
79 struct lustre_sb_info *lsi = s2lsi(sb); in lustre_process_log()
94 lustre_cfg_bufs_set(bufs, 3, &sb, sizeof(sb)); in lustre_process_log()
116 int lustre_end_log(struct super_block *sb, char *logname, in lustre_end_log() argument
121 struct lustre_sb_info *lsi = s2lsi(sb); in lustre_end_log()
203 int lustre_start_mgc(struct super_block *sb) in lustre_start_mgc() argument
206 struct lustre_sb_info *lsi = s2lsi(sb); in lustre_start_mgc()
417 static int lustre_stop_mgc(struct super_block *sb) in lustre_stop_mgc() argument
[all …]
/drivers/staging/lustre/lustre/llite/
Dllite_lib.c67 static struct ll_sb_info *ll_init_sbi(struct super_block *sb) in ll_init_sbi() argument
131 sbi->ll_sb = sb; in ll_init_sbi()
136 static void ll_free_sbi(struct super_block *sb) in ll_free_sbi() argument
138 struct ll_sb_info *sbi = ll_s2sbi(sb); in ll_free_sbi()
143 static int client_common_fill_super(struct super_block *sb, char *md, char *dt, in client_common_fill_super() argument
147 struct ll_sb_info *sbi = ll_s2sbi(sb); in client_common_fill_super()
175 err = ldebugfs_register_mountpoint(llite_root, sb, dt, md); in client_common_fill_super()
213 if (sb->s_flags & MS_RDONLY) in client_common_fill_super()
298 sb->s_blocksize = osfs->os_bsize; in client_common_fill_super()
299 sb->s_blocksize_bits = log2(osfs->os_bsize); in client_common_fill_super()
[all …]
Dllite_nfs.c85 struct inode *search_inode_for_lustre(struct super_block *sb, in search_inode_for_lustre() argument
88 struct ll_sb_info *sbi = ll_s2sbi(sb); in search_inode_for_lustre()
99 inode = ilookup5(sb, hash, ll_nfs_test_inode, (void *)fid); in search_inode_for_lustre()
125 rc = ll_prep_inode(&inode, req, sb, NULL); in search_inode_for_lustre()
139 ll_iget_for_nfs(struct super_block *sb, struct lu_fid *fid, struct lu_fid *parent) in ll_iget_for_nfs() argument
148 inode = search_inode_for_lustre(sb, fid); in ll_iget_for_nfs()
257 static struct dentry *ll_fh_to_dentry(struct super_block *sb, struct fid *fid, in ll_fh_to_dentry() argument
265 return ll_iget_for_nfs(sb, &nfs_fid->lnf_child, &nfs_fid->lnf_parent); in ll_fh_to_dentry()
268 static struct dentry *ll_fh_to_parent(struct super_block *sb, struct fid *fid, in ll_fh_to_parent() argument
276 return ll_iget_for_nfs(sb, &nfs_fid->lnf_parent, NULL); in ll_fh_to_parent()
Dllite_internal.h661 struct super_block *sb, char *osc, char *mdc);
683 struct inode *ll_iget(struct super_block *sb, ino_t hash,
763 int ll_fill_super(struct super_block *sb, struct vfsmount *mnt);
764 void ll_put_super(struct super_block *sb);
765 void ll_kill_super(struct super_block *sb);
771 int ll_statfs_internal(struct super_block *sb, struct obd_statfs *osfs,
779 void ll_umount_begin(struct super_block *sb);
780 int ll_remount_fs(struct super_block *sb, int *flags, char *data);
795 char *ll_get_fsname(struct super_block *sb, char *buf, int buflen);
796 void ll_open_cleanup(struct super_block *sb, struct ptlrpc_request *open_req);
[all …]
/drivers/hwmon/
Dhwmon.c237 struct pci_dev *sb; in hwmon_pci_quirks() local
242 sb = pci_get_device(PCI_VENDOR_ID_ATI, 0x436c, NULL); in hwmon_pci_quirks()
243 if (sb) { in hwmon_pci_quirks()
244 if (sb->subsystem_vendor == 0x1462 && /* MSI */ in hwmon_pci_quirks()
245 sb->subsystem_device == 0x0031) { /* MS-7031 */ in hwmon_pci_quirks()
246 pci_read_config_byte(sb, 0x48, &enable); in hwmon_pci_quirks()
247 pci_read_config_word(sb, 0x64, &base); in hwmon_pci_quirks()
250 dev_info(&sb->dev, in hwmon_pci_quirks()
252 pci_write_config_word(sb, 0x64, 0x295); in hwmon_pci_quirks()
253 pci_write_config_byte(sb, 0x48, in hwmon_pci_quirks()
[all …]
/drivers/oprofile/
Doprofilefs.c26 static struct inode *oprofilefs_get_inode(struct super_block *sb, int mode) in oprofilefs_get_inode() argument
28 struct inode *inode = new_inode(sb); in oprofilefs_get_inode()
238 static int oprofilefs_fill_super(struct super_block *sb, void *data, int silent) in oprofilefs_fill_super() argument
242 sb->s_blocksize = PAGE_CACHE_SIZE; in oprofilefs_fill_super()
243 sb->s_blocksize_bits = PAGE_CACHE_SHIFT; in oprofilefs_fill_super()
244 sb->s_magic = OPROFILEFS_MAGIC; in oprofilefs_fill_super()
245 sb->s_op = &s_ops; in oprofilefs_fill_super()
246 sb->s_time_gran = 1; in oprofilefs_fill_super()
248 root_inode = oprofilefs_get_inode(sb, S_IFDIR | 0755); in oprofilefs_fill_super()
253 sb->s_root = d_make_root(root_inode); in oprofilefs_fill_super()
[all …]
/drivers/md/
Dmd.c855 static unsigned int calc_sb_csum(mdp_super_t *sb) in calc_sb_csum() argument
858 u32 *sb32 = (u32*)sb; in calc_sb_csum()
862 disk_csum = sb->sb_csum; in calc_sb_csum()
863 sb->sb_csum = 0; in calc_sb_csum()
878 sb->sb_csum = md_csum_fold(disk_csum); in calc_sb_csum()
880 sb->sb_csum = disk_csum; in calc_sb_csum()
955 mdp_super_t *sb; in super_90_load() local
972 sb = page_address(rdev->sb_page); in super_90_load()
974 if (sb->md_magic != MD_SB_MAGIC) { in super_90_load()
980 if (sb->major_version != 0 || in super_90_load()
[all …]
Dbitmap.c424 bitmap_super_t *sb; in bitmap_update_sb() local
432 sb = kmap_atomic(bitmap->storage.sb_page); in bitmap_update_sb()
433 sb->events = cpu_to_le64(bitmap->mddev->events); in bitmap_update_sb()
437 sb->events_cleared = cpu_to_le64(bitmap->events_cleared); in bitmap_update_sb()
438 sb->state = cpu_to_le32(bitmap->flags); in bitmap_update_sb()
440 sb->daemon_sleep = cpu_to_le32(bitmap->mddev->bitmap_info.daemon_sleep/HZ); in bitmap_update_sb()
441 sb->write_behind = cpu_to_le32(bitmap->mddev->bitmap_info.max_write_behind); in bitmap_update_sb()
443 sb->sync_size = cpu_to_le64(bitmap->mddev->resync_max_sectors); in bitmap_update_sb()
444 sb->chunksize = cpu_to_le32(bitmap->mddev->bitmap_info.chunksize); in bitmap_update_sb()
445 sb->nodes = cpu_to_le32(bitmap->mddev->bitmap_info.nodes); in bitmap_update_sb()
[all …]
Ddm-raid.c811 struct dm_raid_superblock *sb; in super_sync() local
814 sb = page_address(rdev->sb_page); in super_sync()
815 failed_devices = le64_to_cpu(sb->failed_devices); in super_sync()
822 memset(sb + 1, 0, rdev->sb_size - sizeof(*sb)); in super_sync()
824 sb->magic = cpu_to_le32(DM_RAID_MAGIC); in super_sync()
825 sb->features = cpu_to_le32(0); /* No features yet */ in super_sync()
827 sb->num_devices = cpu_to_le32(mddev->raid_disks); in super_sync()
828 sb->array_position = cpu_to_le32(rdev->raid_disk); in super_sync()
830 sb->events = cpu_to_le64(mddev->events); in super_sync()
831 sb->failed_devices = cpu_to_le64(failed_devices); in super_sync()
[all …]
/drivers/misc/ibmasm/
Dibmasmfs.c89 static struct inode *ibmasmfs_make_inode(struct super_block *sb, int mode);
90 static void ibmasmfs_create_files (struct super_block *sb);
91 static int ibmasmfs_fill_super (struct super_block *sb, void *data, int silent);
115 static int ibmasmfs_fill_super (struct super_block *sb, void *data, int silent) in ibmasmfs_fill_super() argument
119 sb->s_blocksize = PAGE_CACHE_SIZE; in ibmasmfs_fill_super()
120 sb->s_blocksize_bits = PAGE_CACHE_SHIFT; in ibmasmfs_fill_super()
121 sb->s_magic = IBMASMFS_MAGIC; in ibmasmfs_fill_super()
122 sb->s_op = &ibmasmfs_s_ops; in ibmasmfs_fill_super()
123 sb->s_time_gran = 1; in ibmasmfs_fill_super()
125 root = ibmasmfs_make_inode (sb, S_IFDIR | 0500); in ibmasmfs_fill_super()
[all …]
/drivers/staging/lustre/lustre/include/
Dlustre_disk.h369 #define s2lsi(sb) ((struct lustre_sb_info *)((sb)->s_fs_info)) argument
370 #define s2lsi_nocast(sb) ((sb)->s_fs_info) argument
372 #define get_profile_name(sb) (s2lsi(sb)->lsi_lmd->lmd_profile) argument
373 #define get_mount_flags(sb) (s2lsi(sb)->lsi_lmd->lmd_flags) argument
374 #define get_mntdev_name(sb) (s2lsi(sb)->lsi_lmd->lmd_dev) argument
389 int lustre_start_mgc(struct super_block *sb);
390 void lustre_register_client_fill_super(int (*cfs)(struct super_block *sb,
392 void lustre_register_kill_super_cb(void (*cfs)(struct super_block *sb));
393 int lustre_common_put_super(struct super_block *sb);
/drivers/usb/storage/
Dcypress_atacb.c175 unsigned char *sb = srb->sense_buffer; in cypress_atacb_passthrough() local
176 unsigned char *desc = sb + 8; in cypress_atacb_passthrough()
200 memset(sb, 0, SCSI_SENSE_BUFFERSIZE); in cypress_atacb_passthrough()
203 sb[1] = RECOVERED_ERROR; in cypress_atacb_passthrough()
204 sb[2] = 0; /* ATA PASS THROUGH INFORMATION AVAILABLE */ in cypress_atacb_passthrough()
205 sb[3] = 0x1D; in cypress_atacb_passthrough()
214 sb[0] = 0x72; in cypress_atacb_passthrough()
218 sb[7] = 14; in cypress_atacb_passthrough()
/drivers/gpu/drm/qxl/
Dqxl_kms.c123 int r, sb; in qxl_device_init() local
145 sb = 4; in qxl_device_init()
146 qdev->surfaceram_base = pci_resource_start(pdev, sb); in qxl_device_init()
147 qdev->surfaceram_size = pci_resource_len(pdev, sb); in qxl_device_init()
154 sb = 1; in qxl_device_init()
155 qdev->surfaceram_base = pci_resource_start(pdev, sb); in qxl_device_init()
156 qdev->surfaceram_size = pci_resource_len(pdev, sb); in qxl_device_init()
168 (unsigned long long)pci_resource_end(pdev, sb), in qxl_device_init()
171 (sb == 4) ? "64bit" : "32bit"); in qxl_device_init()
/drivers/net/ethernet/broadcom/
Dsb1250-mac.c786 struct sk_buff *sb) in sbdma_add_rcvbuffer() argument
828 if (sb == NULL) { in sbdma_add_rcvbuffer()
838 sb_new = sb; in sbdma_add_rcvbuffer()
901 static int sbdma_add_txbuffer(struct sbmacdma *d, struct sk_buff *sb) in sbdma_add_txbuffer() argument
930 length = sb->len; in sbdma_add_txbuffer()
939 phys = virt_to_phys(sb->data); in sbdma_add_txbuffer()
958 d->sbdma_ctxtable[dsc-d->sbdma_dscrtable] = sb; in sbdma_add_txbuffer()
993 struct sk_buff *sb; in sbdma_emptyring() local
996 sb = d->sbdma_ctxtable[idx]; in sbdma_emptyring()
997 if (sb) { in sbdma_emptyring()
[all …]
/drivers/atm/
Dnicstar.c141 static void dequeue_sm_buf(ns_dev * card, struct sk_buff *sb);
202 struct sk_buff *sb; in nicstar_remove_one() local
239 while ((sb = skb_dequeue(&card->sbpool.queue)) != NULL) in nicstar_remove_one()
240 dev_kfree_skb_any(sb); in nicstar_remove_one()
710 struct sk_buff *sb; in ns_init_card() local
711 sb = __dev_alloc_skb(NS_SMSKBSIZE, GFP_KERNEL); in ns_init_card()
712 if (sb == NULL) { in ns_init_card()
720 NS_PRV_BUFTYPE(sb) = BUF_SM; in ns_init_card()
721 skb_queue_tail(&card->sbpool.queue, sb); in ns_init_card()
722 skb_reserve(sb, NS_AAL0_HEADER); in ns_init_card()
[all …]
/drivers/cpufreq/
Dsfi-cpufreq.c33 struct sfi_table_simple *sb; in sfi_parse_freq() local
37 sb = (struct sfi_table_simple *)table; in sfi_parse_freq()
38 num_freq_table_entries = SFI_GET_NUM_ENTRIES(sb, in sfi_parse_freq()
45 pentry = (struct sfi_freq_table_entry *)sb->pentry; in sfi_parse_freq()
/drivers/iio/imu/inv_mpu6050/
Dinv_mpu_acpi.c96 struct acpi_resource_i2c_serialbus *sb; in acpi_i2c_check_resource() local
98 sb = &ares->data.i2c_serial_bus; in acpi_i2c_check_resource()
99 if (sb->type == ACPI_RESOURCE_SERIAL_TYPE_I2C) { in acpi_i2c_check_resource()
101 *addr |= (sb->slave_address << 16); in acpi_i2c_check_resource()
103 *addr = sb->slave_address; in acpi_i2c_check_resource()
/drivers/staging/rdma/ipath/
Dipath_fs.c225 static int create_device_files(struct super_block *sb, in create_device_files() argument
233 ret = create_file(unit, S_IFDIR|S_IRUGO|S_IXUGO, sb->s_root, &dir, in create_device_files()
290 static int remove_device_files(struct super_block *sb, in remove_device_files() argument
297 root = dget(sb->s_root); in remove_device_files()
319 static int ipathfs_fill_super(struct super_block *sb, void *data, in ipathfs_fill_super() argument
331 ret = simple_fill_super(sb, IPATHFS_MAGIC, files); in ipathfs_fill_super()
341 ret = create_device_files(sb, dd); in ipathfs_fill_super()

1234