~ubuntu-branches/ubuntu/precise/nvidia-settings/precise

« back to all changes in this revision

Viewing changes to src/gtk+-2.x/ctkdisplayconfig-utils.c

  • Committer: Bazaar Package Importer
  • Author(s): Alberto Milone
  • Date: 2010-03-05 11:19:05 UTC
  • mfrom: (1.1.10 upstream)
  • Revision ID: james.westby@ubuntu.com-20100305111905-4ximslurqdws2jtk
Tags: 195.36.08-0ubuntu1
* New upstream release:
  - Fixed an X server crash caused by starting nvidia-settings while
    X was not on the active VT.
  - Fixed an nvidia-settings bug that produced many "Bad argument"
    warning messages when running nvidia-settings --query all.
* Drop patches 03_xf86vidmode-rampsize-check.patch and
  04_include_xf86vmproto.patch as the problem is fixed
  in the upstream code now.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1851
1851
    if (display->is_sdi && !gpu->gvo_mode_data) {
1852
1852
        unsigned int valid1 = 0;
1853
1853
        unsigned int valid2 = 0;
 
1854
        unsigned int valid3 = 0;
1854
1855
        NVCTRLAttributeValidValuesRec valid;
1855
1856
 
1856
1857
        ret = NvCtrlGetValidAttributeValues(gpu->handle,
1873
1874
            valid2 = valid.u.bits.ints;
1874
1875
        }
1875
1876
 
 
1877
        ret = NvCtrlGetValidAttributeValues(gpu->handle,
 
1878
                                            NV_CTRL_GVIO_REQUESTED_VIDEO_FORMAT3,
 
1879
                                            &valid);
 
1880
        if ((ret != NvCtrlSuccess) ||
 
1881
            (valid.type != ATTRIBUTE_TYPE_INT_BITS)) {
 
1882
            valid3 = 0;
 
1883
        } else {
 
1884
            valid3 = valid.u.bits.ints;
 
1885
        }
 
1886
 
1876
1887
        /* Count the number of valid modes there are */
1877
1888
        gpu->num_gvo_modes = count_number_of_bits(valid1);
1878
1889
        gpu->num_gvo_modes += count_number_of_bits(valid2);
 
1890
        gpu->num_gvo_modes += count_number_of_bits(valid3);
1879
1891
        if (gpu->num_gvo_modes > 0) {
1880
1892
            gpu->gvo_mode_data = (GvoModeData *)calloc(gpu->num_gvo_modes,
1881
1893
                                                       sizeof(GvoModeData));
1903
1915
                }
1904
1916
                valid2 >>= 1;
1905
1917
                id++;
1906
 
            }                
 
1918
            }
 
1919
            while (valid3) {
 
1920
                if (valid3 & 1) {
 
1921
                    if (gpu_query_gvo_mode_info(gpu, id, idx)) {
 
1922
                        idx++;
 
1923
                    }
 
1924
                }
 
1925
                valid3 >>= 1;
 
1926
                id++;
 
1927
            }
1907
1928
        }
1908
1929
    }
1909
1930