Changeset 2b3dd78 in mainline for uspace/srv
- Timestamp:
- 2018-01-31T12:02:00Z (8 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 5595841
- Parents:
- a0a9cc2 (diff), 14d789c (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)links above to see all the changes relative to each parent. - Location:
- uspace/srv
- Files:
-
- 39 edited
-
audio/hound/audio_data.c (modified) (4 diffs)
-
audio/hound/audio_data.h (modified) (2 diffs)
-
audio/hound/audio_sink.h (modified) (1 diff)
-
audio/hound/audio_source.c (modified) (1 diff)
-
audio/hound/audio_source.h (modified) (2 diffs)
-
audio/hound/hound.c (modified) (5 diffs)
-
audio/hound/hound.h (modified) (1 diff)
-
audio/hound/hound_ctx.h (modified) (1 diff)
-
audio/hound/iface.c (modified) (1 diff)
-
bd/file_bd/file_bd.c (modified) (1 diff)
-
bd/vbd/disk.h (modified) (1 diff)
-
devman/devman.h (modified) (1 diff)
-
devman/driver.c (modified) (1 diff)
-
devman/match.c (modified) (1 diff)
-
fs/cdfs/cdfs.c (modified) (1 diff)
-
fs/exfat/exfat.c (modified) (1 diff)
-
fs/exfat/exfat_bitmap.h (modified) (1 diff)
-
fs/exfat/exfat_directory.h (modified) (2 diffs)
-
fs/exfat/exfat_fat.h (modified) (1 diff)
-
fs/ext4fs/ext4fs.c (modified) (1 diff)
-
fs/fat/fat.c (modified) (1 diff)
-
fs/fat/fat_directory.h (modified) (1 diff)
-
fs/locfs/locfs.c (modified) (1 diff)
-
fs/locfs/locfs.h (modified) (1 diff)
-
fs/mfs/mfs_dentry.c (modified) (1 diff)
-
fs/mfs/mfs_ops.c (modified) (1 diff)
-
fs/tmpfs/tmpfs.c (modified) (1 diff)
-
hid/console/console.c (modified) (1 diff)
-
hid/input/input.c (modified) (1 diff)
-
hid/isdv4_tablet/isdv4.h (modified) (1 diff)
-
hid/isdv4_tablet/main.c (modified) (1 diff)
-
hid/output/output.h (modified) (1 diff)
-
hid/output/proto/vt100.h (modified) (1 diff)
-
hid/remcons/remcons.c (modified) (1 diff)
-
hid/rfb/main.c (modified) (1 diff)
-
net/dhcp/dhcp.c (modified) (1 diff)
-
net/dnsrsrv/dnsrsrv.c (modified) (1 diff)
-
net/loopip/loopip.c (modified) (1 diff)
-
net/tcp/ncsim.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/audio/hound/audio_data.c
ra0a9cc2 r2b3dd78 36 36 #include <macros.h> 37 37 #include <stdlib.h> 38 #include <str.h> 38 39 39 40 #include "audio_data.h" … … 50 51 pcm_format_t format) 51 52 { 52 audio_data_t *adata = malloc(sizeof(audio_data_t) );53 audio_data_t *adata = malloc(sizeof(audio_data_t) + size); 53 54 if (adata) { 54 55 unsigned overflow = size % pcm_format_frame_size(&format); … … 56 57 log_warning("Data not a multiple of frame size, " 57 58 "clipping."); 58 59 adata->data = data;59 uint8_t *d = ((uint8_t *)adata) + offsetof(audio_data_t, data); 60 memcpy(d, data, size); 60 61 adata->size = size - overflow; 61 62 adata->format = format; … … 86 87 atomic_count_t refc = atomic_predec(&adata->refcount); 87 88 if (refc == 0) { 88 free(adata->data);89 89 free(adata); 90 90 } -
uspace/srv/audio/hound/audio_data.h
ra0a9cc2 r2b3dd78 45 45 /** Reference counted audio buffer */ 46 46 typedef struct { 47 /** Audio data */48 const void *data;49 47 /** Size of the buffer pointer to by data */ 50 48 size_t size; … … 53 51 /** Reference counter */ 54 52 atomic_t refcount; 53 /** Audio data */ 54 const uint8_t data[]; 55 55 } audio_data_t; 56 56 -
uspace/srv/audio/hound/audio_sink.h
ra0a9cc2 r2b3dd78 54 54 list_t connections; 55 55 /** Sink's name */ 56 c onst char *name;56 char *name; 57 57 /** Consumes data in this format */ 58 58 pcm_format_t format; -
uspace/srv/audio/hound/audio_source.c
ra0a9cc2 r2b3dd78 96 96 * @return Error code. 97 97 */ 98 errno_t audio_source_push_data(audio_source_t *source, constvoid *data,98 errno_t audio_source_push_data(audio_source_t *source, void *data, 99 99 size_t size) 100 100 { -
uspace/srv/audio/hound/audio_source.h
ra0a9cc2 r2b3dd78 49 49 list_t connections; 50 50 /** String identifier */ 51 c onst char *name;51 char *name; 52 52 /** audio data format */ 53 53 pcm_format_t format; … … 75 75 const pcm_format_t *f); 76 76 void audio_source_fini(audio_source_t *source); 77 errno_t audio_source_push_data(audio_source_t *source, constvoid *data,77 errno_t audio_source_push_data(audio_source_t *source, void *data, 78 78 size_t size); 79 79 static inline const pcm_format_t *audio_source_format(const audio_source_t *s) -
uspace/srv/audio/hound/hound.c
ra0a9cc2 r2b3dd78 37 37 #include <assert.h> 38 38 #include <stdlib.h> 39 #include <str.h> 39 40 40 41 #include "hound.h" … … 413 414 * @return Error code. 414 415 */ 415 errno_t hound_list_sources(hound_t *hound, c onst char ***list, size_t *size)416 errno_t hound_list_sources(hound_t *hound, char ***list, size_t *size) 416 417 { 417 418 assert(hound); … … 427 428 return EOK; 428 429 } 429 c onst char **names = calloc(count, sizeof(char *));430 char **names = calloc(count, sizeof(char *)); 430 431 errno_t ret = names ? EOK : ENOMEM; 431 432 for (unsigned long i = 0; i < count && ret == EOK; ++i) { … … 455 456 * @return Error code. 456 457 */ 457 errno_t hound_list_sinks(hound_t *hound, c onst char ***list, size_t *size)458 errno_t hound_list_sinks(hound_t *hound, char ***list, size_t *size) 458 459 { 459 460 assert(hound); … … 469 470 return EOK; 470 471 } 471 c onst char **names = calloc(count, sizeof(char *));472 char **names = calloc(count, sizeof(char *)); 472 473 errno_t ret = names ? EOK : ENOMEM; 473 474 for (size_t i = 0; i < count && ret == EOK; ++i) { -
uspace/srv/audio/hound/hound.h
ra0a9cc2 r2b3dd78 70 70 hound_ctx_t *hound_get_ctx_by_id(hound_t *hound, hound_context_id_t id); 71 71 72 errno_t hound_add_device(hound_t *hound, service_id_t id, const char *name);72 errno_t hound_add_device(hound_t *hound, service_id_t id, const char *name); 73 73 errno_t hound_add_source(hound_t *hound, audio_source_t *source); 74 74 errno_t hound_add_sink(hound_t *hound, audio_sink_t *sink); 75 errno_t hound_list_sources(hound_t *hound, c onst char ***list, size_t *size);76 errno_t hound_list_sinks(hound_t *hound, c onst char ***list, size_t *size);75 errno_t hound_list_sources(hound_t *hound, char ***list, size_t *size); 76 errno_t hound_list_sinks(hound_t *hound, char ***list, size_t *size); 77 77 errno_t hound_list_connections(hound_t *hound, const char ***sources, 78 78 const char ***sinks, size_t *size); 79 79 errno_t hound_remove_source(hound_t *hound, audio_source_t *source); 80 80 errno_t hound_remove_sink(hound_t *hound, audio_sink_t *sink); 81 errno_t hound_connect(hound_t *hound, const char * source_name, const char*sink_name);82 errno_t hound_disconnect(hound_t *hound, const char * source_name, const char*sink_name);81 errno_t hound_connect(hound_t *hound, const char *source_name, const char *sink_name); 82 errno_t hound_disconnect(hound_t *hound, const char *source_name, const char *sink_name); 83 83 84 84 #endif -
uspace/srv/audio/hound/hound_ctx.h
ra0a9cc2 r2b3dd78 69 69 70 70 hound_ctx_stream_t *hound_ctx_create_stream(hound_ctx_t *ctx, int flags, 71 pcm_format_t format, size_t buffer_size);71 pcm_format_t format, size_t buffer_size); 72 72 void hound_ctx_destroy_stream(hound_ctx_stream_t *stream); 73 73 -
uspace/srv/audio/hound/iface.c
ra0a9cc2 r2b3dd78 86 86 } 87 87 88 static errno_t iface_get_list(void *server, c onst char ***list, size_t *size,88 static errno_t iface_get_list(void *server, char ***list, size_t *size, 89 89 const char *connection, int flags) 90 90 { -
uspace/srv/bd/file_bd/file_bd.c
ra0a9cc2 r2b3dd78 52 52 #include <task.h> 53 53 #include <macros.h> 54 #include <str.h> 54 55 55 56 #define NAME "file_bd" -
uspace/srv/bd/vbd/disk.h
ra0a9cc2 r2b3dd78 52 52 extern errno_t vbds_label_delete(service_id_t); 53 53 extern errno_t vbds_part_get_info(vbds_part_id_t, vbd_part_info_t *); 54 extern errno_t vbds_part_create(service_id_t, vbd_part_spec_t *, vbds_part_id_t *);54 extern errno_t vbds_part_create(service_id_t, vbd_part_spec_t *, vbds_part_id_t *); 55 55 extern errno_t vbds_part_delete(vbds_part_id_t); 56 56 extern errno_t vbds_suggest_ptype(service_id_t, label_pcnt_t, label_ptype_t *); -
uspace/srv/devman/devman.h
ra0a9cc2 r2b3dd78 80 80 char *name; 81 81 /** Path to the driver's binary. */ 82 c onst char *binary_path;82 char *binary_path; 83 83 /** List of device ids for device-to-driver matching. */ 84 84 match_id_list_t match_ids; -
uspace/srv/devman/driver.c
ra0a9cc2 r2b3dd78 140 140 141 141 /* Check whether the driver's binary exists. */ 142 struct stat s;142 vfs_stat_t s; 143 143 if (vfs_stat_path(drv->binary_path, &s) != EOK) { 144 144 log_msg(LOG_DEFAULT, LVL_ERROR, "Driver not found at path `%s'.", -
uspace/srv/devman/match.c
ra0a9cc2 r2b3dd78 200 200 int fd; 201 201 size_t len = 0; 202 struct stat st;202 vfs_stat_t st; 203 203 204 204 errno_t rc = vfs_lookup_open(conf_path, WALK_REGULAR, MODE_READ, &fd); -
uspace/srv/fs/cdfs/cdfs.c
ra0a9cc2 r2b3dd78 44 44 #include <stdio.h> 45 45 #include <libfs.h> 46 #include <str.h> 46 47 #include "cdfs.h" 47 48 #include "cdfs_ops.h" -
uspace/srv/fs/exfat/exfat.c
ra0a9cc2 r2b3dd78 47 47 #include <stdio.h> 48 48 #include <libfs.h> 49 #include <str.h> 49 50 #include "../../vfs/vfs.h" 50 51 -
uspace/srv/fs/exfat/exfat_bitmap.h
ra0a9cc2 r2b3dd78 42 42 struct exfat_bs; 43 43 44 extern errno_t exfat_bitmap_alloc_clusters(struct exfat_bs *, service_id_t, 44 extern errno_t exfat_bitmap_alloc_clusters(struct exfat_bs *, service_id_t, 45 45 exfat_cluster_t *, exfat_cluster_t); 46 extern errno_t exfat_bitmap_append_clusters(struct exfat_bs *, struct exfat_node *, 46 extern errno_t exfat_bitmap_append_clusters(struct exfat_bs *, struct exfat_node *, 47 47 exfat_cluster_t); 48 extern errno_t exfat_bitmap_free_clusters(struct exfat_bs *, struct exfat_node *, 48 extern errno_t exfat_bitmap_free_clusters(struct exfat_bs *, struct exfat_node *, 49 49 exfat_cluster_t); 50 extern errno_t exfat_bitmap_replicate_clusters(struct exfat_bs *, struct exfat_node *); 50 extern errno_t exfat_bitmap_replicate_clusters(struct exfat_bs *, struct exfat_node *); 51 51 52 52 extern errno_t exfat_bitmap_is_free(struct exfat_bs *, service_id_t, exfat_cluster_t); 53 53 extern errno_t exfat_bitmap_set_cluster(struct exfat_bs *, service_id_t, exfat_cluster_t); 54 extern errno_t exfat_bitmap_clear_cluster(struct exfat_bs *, service_id_t, 54 extern errno_t exfat_bitmap_clear_cluster(struct exfat_bs *, service_id_t, 55 55 exfat_cluster_t); 56 56 57 extern errno_t exfat_bitmap_set_clusters(struct exfat_bs *, service_id_t, 57 extern errno_t exfat_bitmap_set_clusters(struct exfat_bs *, service_id_t, 58 58 exfat_cluster_t, exfat_cluster_t); 59 extern errno_t exfat_bitmap_clear_clusters(struct exfat_bs *, service_id_t, 59 extern errno_t exfat_bitmap_clear_clusters(struct exfat_bs *, service_id_t, 60 60 exfat_cluster_t, exfat_cluster_t); 61 61 -
uspace/srv/fs/exfat/exfat_directory.h
ra0a9cc2 r2b3dd78 29 29 /** @addtogroup fs 30 30 * @{ 31 */ 31 */ 32 32 33 33 #ifndef EXFAT_EXFAT_DIRECTORY_H_ … … 66 66 extern errno_t exfat_directory_find(exfat_directory_t *, exfat_dentry_clsf_t, 67 67 exfat_dentry_t **); 68 extern errno_t exfat_directory_find_continue(exfat_directory_t *, 68 extern errno_t exfat_directory_find_continue(exfat_directory_t *, 69 69 exfat_dentry_clsf_t, exfat_dentry_t **); 70 70 -
uspace/srv/fs/exfat/exfat_fat.h
ra0a9cc2 r2b3dd78 61 61 exfat_cluster_walk((bs), (sid), (fc), NULL, (numc), (uint32_t) -1) 62 62 63 extern errno_t exfat_cluster_walk(struct exfat_bs *, service_id_t, 63 extern errno_t exfat_cluster_walk(struct exfat_bs *, service_id_t, 64 64 exfat_cluster_t, exfat_cluster_t *, uint32_t *, uint32_t); 65 65 extern errno_t exfat_block_get(block_t **, struct exfat_bs *, struct exfat_node *, -
uspace/srv/fs/ext4fs/ext4fs.c
ra0a9cc2 r2b3dd78 42 42 #include <task.h> 43 43 #include <ipc/services.h> 44 #include <str.h> 44 45 #include "ext4/ops.h" 45 46 #include "../../vfs/vfs.h" -
uspace/srv/fs/fat/fat.c
ra0a9cc2 r2b3dd78 47 47 #include <stdio.h> 48 48 #include <libfs.h> 49 #include <str.h> 49 50 #include "../../vfs/vfs.h" 50 51 -
uspace/srv/fs/fat/fat_directory.h
ra0a9cc2 r2b3dd78 29 29 /** @addtogroup fs 30 30 * @{ 31 */ 31 */ 32 32 33 33 #ifndef FAT_FAT_DIRECTORY_H_ -
uspace/srv/fs/locfs/locfs.c
ra0a9cc2 r2b3dd78 47 47 #include <task.h> 48 48 #include <libfs.h> 49 #include <str.h> 49 50 #include "locfs.h" 50 51 #include "locfs_ops.h" -
uspace/srv/fs/locfs/locfs.h
ra0a9cc2 r2b3dd78 29 29 /** @addtogroup fs 30 30 * @{ 31 */ 31 */ 32 32 33 33 #ifndef LOCFS_LOCFS_H_ -
uspace/srv/fs/mfs/mfs_dentry.c
ra0a9cc2 r2b3dd78 31 31 */ 32 32 33 #include <str.h> 33 34 #include "mfs.h" 34 35 -
uspace/srv/fs/mfs/mfs_ops.c
ra0a9cc2 r2b3dd78 36 36 #include <adt/hash_table.h> 37 37 #include <adt/hash.h> 38 #include <str.h> 38 39 #include "mfs.h" 39 40 -
uspace/srv/fs/tmpfs/tmpfs.c
ra0a9cc2 r2b3dd78 50 50 #include <task.h> 51 51 #include <libfs.h> 52 #include <str.h> 52 53 #include "../../vfs/vfs.h" 53 54 -
uspace/srv/hid/console/console.c
ra0a9cc2 r2b3dd78 51 51 #include <fibril_synch.h> 52 52 #include <stdlib.h> 53 #include <str.h> 53 54 #include "console.h" 54 55 -
uspace/srv/hid/input/input.c
ra0a9cc2 r2b3dd78 54 54 #include <stdio.h> 55 55 #include <stdlib.h> 56 #include <str.h> 56 57 #include <str_error.h> 57 58 -
uspace/srv/hid/isdv4_tablet/isdv4.h
ra0a9cc2 r2b3dd78 74 74 75 75 typedef enum { 76 UNKNOWN, PRESS, RELEASE, PROXIMITY_IN, PROXIMITY_OUT, MOVE 76 UNKNOWN, 77 PRESS, 78 RELEASE, 79 PROXIMITY_IN, 80 PROXIMITY_OUT, 81 MOVE 77 82 } isdv4_event_type_t; 78 83 79 84 typedef enum { 80 STYLUS_TIP, STYLUS_ERASER, TOUCH 85 STYLUS_TIP, 86 STYLUS_ERASER, 87 TOUCH 81 88 } isdv4_source_type_t; 82 89 -
uspace/srv/hid/isdv4_tablet/main.c
ra0a9cc2 r2b3dd78 35 35 #include <stddef.h> 36 36 #include <stdio.h> 37 #include <str.h> 37 38 #include <task.h> 38 39 -
uspace/srv/hid/output/output.h
ra0a9cc2 r2b3dd78 42 42 43 43 typedef struct { 44 errno_t (* yield)(struct outdev *dev);45 errno_t (* claim)(struct outdev *dev);44 errno_t (*yield)(struct outdev *dev); 45 errno_t (*claim)(struct outdev *dev); 46 46 47 void (* get_dimensions)(struct outdev *dev, sysarg_t *cols,47 void (*get_dimensions)(struct outdev *dev, sysarg_t *cols, 48 48 sysarg_t *rows); 49 console_caps_t (* get_caps)(struct outdev *dev);49 console_caps_t (*get_caps)(struct outdev *dev); 50 50 51 void (* cursor_update)(struct outdev *dev, sysarg_t prev_col,51 void (*cursor_update)(struct outdev *dev, sysarg_t prev_col, 52 52 sysarg_t prev_row, sysarg_t col, sysarg_t row, bool visible); 53 void (* char_update)(struct outdev *dev, sysarg_t col, sysarg_t row);54 void (* flush)(struct outdev *dev);53 void (*char_update)(struct outdev *dev, sysarg_t col, sysarg_t row); 54 void (*flush)(struct outdev *dev); 55 55 } outdev_ops_t; 56 56 -
uspace/srv/hid/output/proto/vt100.h
ra0a9cc2 r2b3dd78 35 35 #include <io/charfield.h> 36 36 37 typedef void (* vt100_putchar_t)(wchar_t ch);38 typedef void (* vt100_control_puts_t)(const char *str);39 typedef void (* vt100_flush_t)(void);37 typedef void (*vt100_putchar_t)(wchar_t ch); 38 typedef void (*vt100_control_puts_t)(const char *str); 39 typedef void (*vt100_flush_t)(void); 40 40 41 41 typedef struct { -
uspace/srv/hid/remcons/remcons.c
ra0a9cc2 r2b3dd78 49 49 #include <io/console.h> 50 50 #include <inttypes.h> 51 #include <str.h> 51 52 #include "telnet.h" 52 53 #include "user.h" -
uspace/srv/hid/rfb/main.c
ra0a9cc2 r2b3dd78 35 35 #include <inttypes.h> 36 36 #include <io/log.h> 37 #include <str.h> 37 38 #include <task.h> 38 39 -
uspace/srv/net/dhcp/dhcp.c
ra0a9cc2 r2b3dd78 48 48 #include <stdio.h> 49 49 #include <stdlib.h> 50 #include <str.h> 50 51 51 52 #include "dhcp.h" -
uspace/srv/net/dnsrsrv/dnsrsrv.c
ra0a9cc2 r2b3dd78 43 43 #include <stdio.h> 44 44 #include <stdlib.h> 45 #include <str.h> 45 46 #include <task.h> 46 47 -
uspace/srv/net/loopip/loopip.c
ra0a9cc2 r2b3dd78 45 45 #include <stdio.h> 46 46 #include <stdlib.h> 47 #include <str.h> 47 48 #include <task.h> 48 49 -
uspace/srv/net/tcp/ncsim.c
ra0a9cc2 r2b3dd78 81 81 return; 82 82 83 if (0 /*rand om() % 4 == 3*/) {83 if (0 /*rand() % 4 == 3*/) { 84 84 /* Drop segment */ 85 85 log_msg(LOG_DEFAULT, LVL_ERROR, "NCSim dropping segment"); … … 94 94 } 95 95 96 sqe->delay = rand om() % (1000 * 1000);96 sqe->delay = rand() % (1000 * 1000); 97 97 sqe->epp = *epp; 98 98 sqe->seg = seg;
Note:
See TracChangeset
for help on using the changeset viewer.
