search for: get_user

Displaying 20 results from an estimated 356 matches for "get_user".

2007 May 04
1
[PATCH 1/3] Documentation and example updates
1) Example code: old libc headers don't have SIOCBRADDIF, and old zlibs don't have gzdirect() -- it's a sanity check anyway. 2) Some people don't build in their source directories, so .config isn't there (thanks to Tony Breeds <tony@bakeyournoodle.com>). 3) Point out that guest and host kernel are usually the same. 4) Set the "no checksum" option on the
2007 May 04
1
[PATCH 1/3] Documentation and example updates
1) Example code: old libc headers don't have SIOCBRADDIF, and old zlibs don't have gzdirect() -- it's a sanity check anyway. 2) Some people don't build in their source directories, so .config isn't there (thanks to Tony Breeds <tony@bakeyournoodle.com>). 3) Point out that guest and host kernel are usually the same. 4) Set the "no checksum" option on the
2019 May 13
5
[PATCH net] vhost: don't use kmap() to log dirty pages
...x is to keep using userspace virtual address. Fortunately, futex has arch_futex_atomic_op_inuser() which could be used for setting a bit to user. Note there're several cases that futex helper can fail e.g a page fault or the arch that doesn't have the support. For those cases, a simplified get_user()/put_user() pair protected by a global mutex is provided as a fallback. The fallback may lead false positive that userspace may see more dirty pages. Cc: Christoph Hellwig <hch at infradead.org> Cc: James Bottomley <James.Bottomley at HansenPartnership.com> Cc: Andrea Arcangeli <aa...
2019 May 13
5
[PATCH net] vhost: don't use kmap() to log dirty pages
...x is to keep using userspace virtual address. Fortunately, futex has arch_futex_atomic_op_inuser() which could be used for setting a bit to user. Note there're several cases that futex helper can fail e.g a page fault or the arch that doesn't have the support. For those cases, a simplified get_user()/put_user() pair protected by a global mutex is provided as a fallback. The fallback may lead false positive that userspace may see more dirty pages. Cc: Christoph Hellwig <hch at infradead.org> Cc: James Bottomley <James.Bottomley at HansenPartnership.com> Cc: Andrea Arcangeli <aa...
2006 Jan 03
2
help me understand association attributes
...attempting to assign the user to the thing. To accomplish this I used a before_save method, like this: class Thing < ActiveRecord::Base belongs_to :created_by, :class_name => "User", :foreign_key => "created_by_user_id" def before_create self.created_by = get_user() end I had trouble getting the assignment to work. I initially tried simply created_by = get_user() (no ''self'') I don''t know why ''self'' made a difference in this case. Can anyone explain this to me? Thank you. -Kelly -------------- next p...
2005 Aug 14
1
Authentication based on client host
Hi, I am wondering if it's possible to authenticate users that come from specific IP differently then other users. I will be authenticating them by postgresql so something like this would be very useful: password_query = SELECT password from get_user('%username','%host') Is that possible? Can it be done any other way? Thanks, Sebastjan
2019 May 14
0
[PATCH net] vhost: don't use kmap() to log dirty pages
...irtual > address. Fortunately, futex has arch_futex_atomic_op_inuser() which > could be used for setting a bit to user. > > Note there're several cases that futex helper can fail e.g a page > fault or the arch that doesn't have the support. For those cases, a > simplified get_user()/put_user() pair protected by a global mutex is > provided as a fallback. The fallback may lead false positive that > userspace may see more dirty pages. > > Cc: Christoph Hellwig <hch at infradead.org> > Cc: James Bottomley <James.Bottomley at HansenPartnership.com> &g...
2013 Jun 19
3
Calling an array in a struct in C to R
Hi there, Although I'm a quite experienced R user and know my ways in C, I stumbled upon a problem I don't know how to solve. Therefore, I hope someone can provide me with the information or pointers I need in order to understand the way in which the communication between R and C occurs. I have the following C code which basicallly reflects what I want: typedef struct { float
2020 May 22
1
Dovecot passdb and postfix login
...the functioning IMAP servers, just copied accross to the authenticated relay server: $ sudo cat /etc/dovecot/local_sql_users.conf driver = pgsql connect = host=foo dbname=bar user=secret password=squirrel default_pass_scheme = ARGON2ID password_query = select dovecot_username as user,password from get_user('%u') user_query = select 'vmail' as uid, 'vmail' as gid iterate_query = select dovecot_username as user from get_users()
2007 Apr 18
0
[PATCH 11/14] i386 / Eliminate yet another redundant accessor
Found yet another set of accessor functions for descriptors that really belongs in desc.h - move it there. Patch-base: 2.6.13-rc5-mm1 Patch-keys: i386 desc cleanup Signed-off-by: Zachary Amsden <zach@vmware.com> Index: linux-2.6.13/arch/i386/kernel/process.c =================================================================== --- linux-2.6.13.orig/arch/i386/kernel/process.c 2005-08-09
2008 Apr 05
11
[PATCH RFC 1/5] vringfd syscall
...*/ + if (vr->ops && vr->ops->pull) { + err = vr->ops->pull(vr->ops_data); + if (unlikely(err < 0)) + return err; + + if (err > 0) { + /* Buffers have been used, no need to check indices */ + mask = POLLIN | POLLRDNORM; + goto poll_wait; + } + } + + err = get_user(used, &vr->ring.used->idx); + if (unlikely(err)) + return err; + + err = get_user(last_used, vr->last_used); + if (unlikely(err)) + return err; + + /* More buffers have been used? It's 'readable'. */ + if (used != last_used) + mask = POLLIN | POLLRDNORM; + else + mask...
2007 Apr 18
0
[PATCH 11/14] i386 / Eliminate yet another redundant accessor
Found yet another set of accessor functions for descriptors that really belongs in desc.h - move it there. Patch-base: 2.6.13-rc5-mm1 Patch-keys: i386 desc cleanup Signed-off-by: Zachary Amsden <zach@vmware.com> Index: linux-2.6.13/arch/i386/kernel/process.c =================================================================== --- linux-2.6.13.orig/arch/i386/kernel/process.c 2005-08-09
2008 Apr 05
11
[PATCH RFC 1/5] vringfd syscall
...*/ + if (vr->ops && vr->ops->pull) { + err = vr->ops->pull(vr->ops_data); + if (unlikely(err < 0)) + return err; + + if (err > 0) { + /* Buffers have been used, no need to check indices */ + mask = POLLIN | POLLRDNORM; + goto poll_wait; + } + } + + err = get_user(used, &vr->ring.used->idx); + if (unlikely(err)) + return err; + + err = get_user(last_used, vr->last_used); + if (unlikely(err)) + return err; + + /* More buffers have been used? It's 'readable'. */ + if (used != last_used) + mask = POLLIN | POLLRDNORM; + else + mask...
2007 Apr 18
2
[PATCH 16/21] i386 Eliminate duplicate segment macros
Get rid of duplicated and ugly segment macros, replacing them with slightly less ugly versions in a more appropriate place. Signed-off-by: Zachary Amsden <zach@vmware.com> Index: linux-2.6.14-zach-work/arch/i386/kernel/process.c =================================================================== --- linux-2.6.14-zach-work.orig/arch/i386/kernel/process.c 2005-11-04 18:07:41.000000000 -0800
2007 Apr 18
2
[PATCH 16/21] i386 Eliminate duplicate segment macros
Get rid of duplicated and ugly segment macros, replacing them with slightly less ugly versions in a more appropriate place. Signed-off-by: Zachary Amsden <zach@vmware.com> Index: linux-2.6.14-zach-work/arch/i386/kernel/process.c =================================================================== --- linux-2.6.14-zach-work.orig/arch/i386/kernel/process.c 2005-11-04 18:07:41.000000000 -0800
2007 May 31
16
Could anyone please help with rspec/nested resource behavior checking?
My problem has been listed here: http://railsforum.com/viewtopic.php?pid=25439#p25439 Don''t think it would be required to completely re-type it here :) Thanks! -- -Daniel Fischer http://danielfischer.com - Geek Blog http://abigfisch.com - Portfolio http://writersbeat.com - Writing Community
2019 Aug 06
2
[PATCH V2 7/9] vhost: do not use RCU to synchronize MMU notifier with worker
On Sun, Aug 04, 2019 at 04:07:17AM -0400, Michael S. Tsirkin wrote: > > > > Also, why can't this just permanently GUP the pages? In fact, where > > > > does it put_page them anyhow? Worrying that 7f466 adds a get_user page > > > > but does not add a put_page?? > > > > You didn't answer this.. Why not just use GUP? > > > > Jason > > Sorry I misunderstood the question. Permanent GUP breaks lots of > functionality we need such as THP and numa balancing. Really? I...
2019 Aug 06
2
[PATCH V2 7/9] vhost: do not use RCU to synchronize MMU notifier with worker
On Sun, Aug 04, 2019 at 04:07:17AM -0400, Michael S. Tsirkin wrote: > > > > Also, why can't this just permanently GUP the pages? In fact, where > > > > does it put_page them anyhow? Worrying that 7f466 adds a get_user page > > > > but does not add a put_page?? > > > > You didn't answer this.. Why not just use GUP? > > > > Jason > > Sorry I misunderstood the question. Permanent GUP breaks lots of > functionality we need such as THP and numa balancing. Really? I...
2006 Jun 30
4
More idiomatic way of writing a filter
Is there a more elegant way of writing this? def verify_user @user = User.find_by_username params[:username] if @user.nil? message = xml.error do |xm| xm.message "User does not exists: #{params[:username]}" end render :xml => message return false else true end end Thanks, Joel --
2011 Jun 21
1
[PATCH 1/2] vhost: init used ring after backend was set
...virtqueue *vq, - struct vring_used __user *used) +int init_used(struct vhost_virtqueue *vq) { - int r = put_user(vq->used_flags, &used->flags); + int r = put_user(vq->used_flags, &vq->used->flags); if (r) return r; vq->signalled_used_valid = false; - return get_user(vq->last_used_idx, &used->idx); + return get_user(vq->last_used_idx, &vq->used->idx); } static long vhost_set_vring(struct vhost_dev *d, int ioctl, void __user *argp) @@ -701,10 +700,6 @@ static long vhost_set_vring(struct vhost_dev *d, int ioctl, void __user *argp) }...